Skip to content

Commit 6733a6a

Browse files
committed
Response with json
1 parent 63b8f10 commit 6733a6a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Middleware/CheckAuth.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class CheckAuth
2020
public function handle($request, Closure $next, $service)
2121
{
2222
if (! $this->authorized($request, $service)) {
23-
return response(self::CODE, self::MESSAGE);
23+
return response()->json(['message' => self::MESSAGE], self::CODE);
2424
}
2525

2626
return $next($request);

0 commit comments

Comments
 (0)