Skip to content

Commit

Permalink
Make sure new parameter are added to configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
LintyDev committed Dec 13, 2023
1 parent 88359e4 commit 50f18d2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions maintain.class.php
Expand Up @@ -51,6 +51,13 @@ function install($plugin_version, &$errors=array())
else
{
$new_conf = is_string($conf['Fotorama']) ? unserialize($conf['Fotorama']) : $conf['Fotorama'];
foreach ($this->default_conf as $conf_key => $conf_value)
{
if (!isset($new_conf[$conf_key]))
{
$new_conf[$conf_key] = $conf_value;
}
}

$conf['Fotorama'] = serialize($new_conf);
conf_update_param('Fotorama', $conf['Fotorama']);
Expand Down

0 comments on commit 50f18d2

Please sign in to comment.