Wedge
Public area => Bug reports => The Pub => Archived fixes => Topic started by: CerealGuy on April 1st, 2015, 01:19 AM
-
apply_plugin_mods() destroys the Settings.php when an error occurs.
array_diff() needs two arrays as arguments but only gets one (the other one is the plugin string).
$enabled_plugins = array_diff($enabled_plugins, $plugin);
I changed it to
$enabled_plugins = array_diff($enabled_plugins, array($plugin));
but perhaps something with array_search and unset would be better.
And updateSettingsFile() wants an assoc but it gets something weird:
updateSettingsFile(array('my_plugins' => $my_plugins = implode(',', $enabled_plugins)));
I changed it to updateSettingsFile(array('my_plugins' => implode(',', $enabled_plugins)));
Will create a pull request...
EDIT:
https://github.com/Wedge/wedge/pull/28
Includes some other fixes