郑晓宇 преди 6 години
родител
ревизия
3db3b9b999
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      app/Console/Commands/gamematch.php

+ 1 - 1
app/Console/Commands/gamematch.php

@@ -54,7 +54,7 @@ class gamematch extends Command
                     $message = [
                         "type" => 'gotomatch',
                     ];
-                    if(Gateway::isOnline($robot)){
+                    if($robot && Gateway::isOnline($robot)){
                         Gateway::sendToClient($robot, $message);
                         echo "启动机器人: {$robot}\n";
                     }