diff options
| author | Elmar Ludwig <elmar.ludwig@uni-osnabrueck.de> | 2023-08-15 11:22:00 +0000 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+github@gmail.com> | 2023-08-15 13:58:08 +0200 |
| commit | a2747c29c24175394375536c44f900cd552ccde9 (patch) | |
| tree | c3d645bd9490f6dcf40f865c69157e1b9eb9f127 /cli | |
| parent | f6aec6e1d8daa6abc0e0bad3bb47f9c2017938b4 (diff) | |
correctly display pending migrations for plugins, fixes #3022
Closes #3022
Merge request studip/studip!2031
Diffstat (limited to 'cli')
| -rw-r--r-- | cli/Commands/Plugins/PluginInfo.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cli/Commands/Plugins/PluginInfo.php b/cli/Commands/Plugins/PluginInfo.php index 492c1ae..e1b00f4 100644 --- a/cli/Commands/Plugins/PluginInfo.php +++ b/cli/Commands/Plugins/PluginInfo.php @@ -35,7 +35,7 @@ class PluginInfo extends AbstractPluginCommand $basepath = \Config::get()->PLUGINS_PATH; foreach ($plugins as $plugin) { - $plugindir = $basepath . '/' . $plugin['path'] . '/'; + $plugindir = $basepath . '/' . $plugin['path']; $plugin['class_exists'] = $this->pluginClassExists($plugindir, $plugin); $plugin['type'] = join(',', $plugin['type']); @@ -43,7 +43,7 @@ class PluginInfo extends AbstractPluginCommand if (is_dir($plugindir . '/migrations')) { $schemaVersion = new \DBSchemaVersion($plugin['name']); $migrator = new \Migrator($plugindir . '/migrations', $schemaVersion); - $plugin['migration_top_version'] = $migrator->topVersion(); + $plugin['pending_migrations'] = count($migrator->relevantMigrations(null)); $plugin['schema_version'] = $schemaVersion->get(); } |
