Commit 9cc3778b authored by Avris's avatar Avris

better error message on failed release

parent c1a409d5
......@@ -117,7 +117,10 @@ class ServerController extends BaseApiController
&& $server->getCurrentStatus()->getUser() !== $projectUser->getUser();
if ($isForce && !$projectUser->getCanManage()) {
throw new UnauthorisedException;
throw new UnauthorisedException(sprintf(
'You cannot release a server, because it\'s currently taken by %s',
$server->getCurrentStatus()->getUser() ?: l('entity.User.system')
if ($isForce) {
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment