Skip to content

Commit

Permalink
Fix setTranslation
Browse files Browse the repository at this point in the history
  • Loading branch information
petrzpav committed Nov 11, 2024
1 parent 0e984cd commit 84cef35
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Traits/Translatable.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,10 @@ public function setTranslation($attribute, $locale, $value)
{
$fallbackLocale = app()->getFallbackLocale();
$this->translations()->updateOrCreate(
['attribute' => $key, 'locale' => $locale],
['attribute' => $attribute, 'locale' => $locale],
['value' => $value]
);
Cache::forget($this->getTraslationCacheKey($key, $locale, $fallbackLocale));
Cache::forget($this->getTraslationCacheKey($attribute, $locale, $fallbackLocale));
}

/**
Expand Down

0 comments on commit 84cef35

Please sign in to comment.