fix: Units class cannot be used as array in PHP 7

This commit is contained in:
Martin Ambrus
2017-10-09 13:08:17 +02:00
parent 0bba324aa8
commit 4774d7965b
+2 -2
View File
@@ -1072,8 +1072,8 @@ class Automation {
$cannotsend = 0;
$movements = $database->getMovement("34",$data['to'],1);
for($y=0;$y < count($movements);$y++){
$returntime = $units[$y]['endtime']-time();
if($units[$y]['sort_type'] == 4 && $units[$y]['from'] != 0 && $returntime <= 10){
$returntime = $units->$y['endtime']-time();
if($units->$y['sort_type'] == 4 && $units->$y['from'] != 0 && $returntime <= 10){
$cannotsend = 1;
}
}