Use Chat::formatMessage in Main-Files
This commit is contained in:
1 parent
965ee220ba
commit
5717589588
2 files changed
+18
-5
No files matched your search
+12
-4
@@ -131,8 +131,12 @@ class ErrorHandler {
|
||||
|
||||
if ($isFatalError) {
|
||||
$this->maniaControl->getPluginManager()->deactivatePlugin($sourceClass);
|
||||
$this->maniaControl->getChat()->sendError("Plugin " . $sourceClass . " has an Error -> The Plugin will be deactivated and ManiaControl restarted");
|
||||
Logger::logError("Plugin " . $sourceClass . " has an Error -> The Plugin will be deactivated and ManiaControl restarted");
|
||||
$message = $this->maniaControl->getChat()->formatMessage(
|
||||
'Plugin %s has an Error -> The Plugin will be deactivated and ManiaControl restarted!',
|
||||
$sourceClass
|
||||
);
|
||||
$this->maniaControl->getChat()->sendError($message);
|
||||
Logger::logError("Plugin {$sourceClass} has an Error -> The Plugin will be deactivated and ManiaControl restarted!");
|
||||
$isPluginError = true;
|
||||
}
|
||||
}
|
||||
@@ -482,8 +486,12 @@ class ErrorHandler {
|
||||
$report['PluginVersion'] = PluginManager::getPluginVersion($sourceClass);
|
||||
|
||||
$this->maniaControl->getPluginManager()->deactivatePlugin($sourceClass);
|
||||
$this->maniaControl->getChat()->sendError("Plugin " . $sourceClass . " has an Error -> The Plugin will be deactivated and ManiaControl restarted");
|
||||
Logger::logError("Plugin " . $sourceClass . " has an Error -> The Plugin will be deactivated and ManiaControl restarted");
|
||||
$message = $this->maniaControl->getChat()->formatMessage(
|
||||
'Plugin %s has an Error -> The Plugin will be deactivated and ManiaControl restarted!',
|
||||
$sourceClass
|
||||
);
|
||||
$this->maniaControl->getChat()->sendError($message);
|
||||
Logger::logError("Plugin {$sourceClass} has an Error -> The Plugin will be deactivated and ManiaControl restarted!");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user