show error in console if information about the phar plugin was not found

This commit is contained in:
GameHerobrine 2025-07-18 17:44:37 +03:00
parent 187a2d0805
commit 92e1411ed3

View file

@ -149,6 +149,10 @@ class PluginAPI extends stdClass{
break;
}
}
if(count($pluginInfo) == 0){
ConsoleAPI::error("Failed to load PHAR plugin from $file: pluginInfo has no information(PHAR was made for PMMP 1.4+?)");
continue;
}
console("[INFO] Loading PHAR plugin \"".FORMAT_GREEN.$pluginInfo["name"].FORMAT_RESET."\" ".FORMAT_AQUA.$pluginInfo["version"].FORMAT_RESET." by ".FORMAT_AQUA.$pluginInfo["author"].FORMAT_RESET);
$aver = CURRENT_API_VERSION;