Utils: Make kill() use static MainLogger instead of global variable

This commit is contained in:
Dylan K. Taylor
2018-06-07 09:29:53 +01:00
parent 5f7c884255
commit 73e56c8a36
2 changed files with 10 additions and 3 deletions

View File

@ -545,9 +545,8 @@ class Utils{
}
public static function kill($pid) : void{
global $logger;
if($logger instanceof MainLogger){
$logger->syncFlushBuffer();
if(MainLogger::isRegisteredStatic()){
MainLogger::getLogger()->syncFlushBuffer();
}
switch(Utils::getOS()){
case "win":