modified RequirePermission middleware

adjusted corp journal to account for when the esi token and refresh aren't found correctly.
will be updating supervisor to add in the queue worker
This commit is contained in:
2019-01-09 19:26:23 -06:00
parent d0cb5f4dd7
commit 78561ec7e3
2 changed files with 33 additions and 1 deletions
@@ -18,7 +18,6 @@ class RequirePermission
*/
public function handle($request, Closure $next, $permission)
{
$perms = UserPermission::where(['character_id' => auth()->user()->character_id, 'permission'=> $permission])->get(['permission']);
abort_unless(auth()->check() && isset($perms[0]->permission), 403, "You don't have the correct permission to be in this area.");