Update logic for tracking a server's transfer state

This commit is contained in:
Matthew Penner 2020-12-16 09:34:47 -07:00
parent 5d03c0d2e5
commit e6c4a68e4a
20 changed files with 206 additions and 74 deletions

View file

@ -61,7 +61,10 @@ class SuspensionService
'suspended' => $action === self::ACTION_SUSPEND,
]);
$this->daemonServerRepository->setServer($server)->suspend($action === self::ACTION_UNSUSPEND);
// Only send the suspension request to wings if the server is not currently being transferred.
if ($server->transfer === null) {
$this->daemonServerRepository->setServer($server)->suspend($action === self::ACTION_UNSUSPEND);
}
});
}
}