diff options
author | Mario Vavti <mario@mariovavti.com> | 2022-04-23 20:53:05 +0200 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2022-04-23 20:53:05 +0200 |
commit | 695045f19740f1f4619a50594b494d81456896c7 (patch) | |
tree | e1a976b1877ed4d0a80950b3fd03a0e991c89e1c | |
parent | 376733bd084350bcb0854b4f6592bb0565fac018 (diff) | |
parent | 4c7c5137c5289fa07695eff21c521343bedd954f (diff) | |
download | volse-hubzilla-695045f19740f1f4619a50594b494d81456896c7.tar.gz volse-hubzilla-695045f19740f1f4619a50594b494d81456896c7.tar.bz2 volse-hubzilla-695045f19740f1f4619a50594b494d81456896c7.zip |
Merge branch 'dev' of https://framagit.org/hubzilla/core into dev
-rw-r--r-- | include/plugin.php | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/include/plugin.php b/include/plugin.php index f9cee7ed6..a17f5761d 100644 --- a/include/plugin.php +++ b/include/plugin.php @@ -275,13 +275,16 @@ function plugins_sync() { if(! array_walk($plugins_arr,'array_trim')) return; - App::$plugins = $plugins_arr; - $installed_arr = []; if(count($installed)) { foreach($installed as $i) { - if(! in_array($i, $plugins_arr)) { + if (! file_exists('addon/' . $i . '/' . $i . '.php')) { + q("DELETE FROM addon WHERE aname = '%s' ", + dbesc($i) + ); + } + elseif(! in_array($i, $plugins_arr)) { unload_plugin($i); } else { @@ -298,6 +301,8 @@ function plugins_sync() { } } + App::$plugins = $installed_arr; + } |