mirror of
https://github.com/humhub/humhub.git
synced 2025-03-14 20:19:47 +01:00
- Fix: Only flush js config if not empty.
This commit is contained in:
parent
d0c38973e6
commit
08bda5c05e
@ -265,8 +265,9 @@ class View extends \yii\web\View
|
||||
*/
|
||||
protected function flushJsConfig($key = null)
|
||||
{
|
||||
$this->registerJs("humhub.config.set(" . json_encode($this->jsConfig) . ");", View::POS_BEGIN, $key);
|
||||
$this->jsConfig = [];
|
||||
if(!empty($this->jsConfig)) {
|
||||
$this->registerJs("humhub.config.set(" . json_encode($this->jsConfig) . ");", View::POS_BEGIN, $key);
|
||||
$this->jsConfig = [];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user