mirror of
https://github.com/lkddi/Xboard.git
synced 2026-04-14 11:20:53 +08:00
fix(plugin): remove stale plugin records when files missing; adjust logging
This commit is contained in:
@@ -53,7 +53,8 @@ class PluginManager
|
||||
if (!class_exists($pluginClass)) {
|
||||
$pluginFile = $this->getPluginPath($pluginCode) . '/Plugin.php';
|
||||
if (!File::exists($pluginFile)) {
|
||||
Log::error("Plugin class file not found: {$pluginFile}");
|
||||
Log::warning("Plugin class file not found: {$pluginFile}");
|
||||
Plugin::query()->where('code', $pluginCode)->delete();
|
||||
return null;
|
||||
}
|
||||
require_once $pluginFile;
|
||||
|
||||
Reference in New Issue
Block a user