Skip to content

Commit 9af543b

Browse files
authored
Update Translate.php
1 parent 2f0710d commit 9af543b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Eloquent/Translate.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ class Translate implements JsonSerializable {
2525
*/
2626
public function __construct($string = '', $domain = '')
2727
{
28-
$decode = is_string($string) ? json_decode($string, true) : $string;
28+
$decode = is_string($string) ? json_decode($string, true) : $string;
2929
$this->translations = $decode ? $decode : [
30-
config('app.fallback_locale') => $string
30+
config('app.fallback_locale') => $string != '{}' ? $string : null
3131
];
3232
$this->locale = Translator::getLocale();
3333
}

0 commit comments

Comments
 (0)