mirror of
https://github.com/wintercms/winter.git
synced 2024-06-28 05:33:29 +02:00
Only attempt to translate string values
Fixes #4398. Credit to @w20k for finding the issue.
This commit is contained in:
parent
6f583b3920
commit
f9f337e664
@ -450,7 +450,11 @@ class ReportContainer extends WidgetBase
|
||||
|
||||
$properties = $widget->defineProperties();
|
||||
foreach ($properties as $name => $params) {
|
||||
$result[$name] = Lang::get($widget->property($name));
|
||||
$value = $widget->property($name);
|
||||
if (is_string($value)) {
|
||||
$value = Lang::get($value);
|
||||
}
|
||||
$result[$name] = $value;
|
||||
}
|
||||
|
||||
$result['ocWidgetWidth'] = $widget->property('ocWidgetWidth');
|
||||
@ -507,4 +511,4 @@ class ReportContainer extends WidgetBase
|
||||
{
|
||||
return 'backend::reportwidgets.default.'.$this->context;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user