Fix inner join bug
This commit is contained in:
parent
022143dd86
commit
65a91baa16
2 changed files with 2 additions and 2 deletions
|
@ -25,7 +25,7 @@ class CheckServer
|
||||||
|
|
||||||
$server = Server::getByUUID($request->route()->server);
|
$server = Server::getByUUID($request->route()->server);
|
||||||
if (!$server) {
|
if (!$server) {
|
||||||
return redirect()->route('index');
|
return response()->view('errors.403', [], 403);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($server->installed !== 1) {
|
if ($server->installed !== 1) {
|
||||||
|
|
|
@ -113,7 +113,7 @@ class Server extends Model
|
||||||
}
|
}
|
||||||
|
|
||||||
$query = self::select('servers.*', 'services.file as a_serviceFile')
|
$query = self::select('servers.*', 'services.file as a_serviceFile')
|
||||||
->join('services', 'services.id', '=', 'servers.id')
|
->join('services', 'services.id', '=', 'servers.service')
|
||||||
->where('uuidShort', $uuid)->where('active', 1);
|
->where('uuidShort', $uuid)->where('active', 1);
|
||||||
|
|
||||||
if (self::$user->root_admin !== 1) {
|
if (self::$user->root_admin !== 1) {
|
||||||
|
|
Loading…
Reference in a new issue