Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
laravel-adminpanel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
laravel-adminpanel
Commits
790f93a5
Unverified
Commit
790f93a5
authored
Mar 14, 2018
by
Viral Solani
Committed by
GitHub
Mar 14, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #186 from viralsolani/analysis-zYmBlj
Apply fixes from StyleCI
parents
08fdc5a4
383ce7c3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
Handler.php
app/Exceptions/Handler.php
+4
-4
RoleResource.php
app/Http/Resources/RoleResource.php
+1
-1
No files found.
app/Exceptions/Handler.php
View file @
790f93a5
...
@@ -77,10 +77,10 @@ class Handler extends ExceptionHandler
...
@@ -77,10 +77,10 @@ class Handler extends ExceptionHandler
return
$this
->
setStatusCode
(
422
)
->
respondWithError
(
$exception
->
validator
->
messages
());
return
$this
->
setStatusCode
(
422
)
->
respondWithError
(
$exception
->
validator
->
messages
());
}
}
/*
/*
* Redirect if token mismatch error
* Redirect if token mismatch error
* Usually because user stayed on the same screen too long and their session expired
* Usually because user stayed on the same screen too long and their session expired
*/
*/
if
(
$exception
instanceof
UnauthorizedHttpException
)
{
if
(
$exception
instanceof
UnauthorizedHttpException
)
{
switch
(
get_class
(
$exception
->
getPrevious
()))
{
switch
(
get_class
(
$exception
->
getPrevious
()))
{
case
\App\Exceptions\Handler
::
class
:
case
\App\Exceptions\Handler
::
class
:
...
...
app/Http/Resources/RoleResource.php
View file @
790f93a5
...
@@ -21,7 +21,7 @@ class RoleResource extends Resource
...
@@ -21,7 +21,7 @@ class RoleResource extends Resource
'permission'
=>
(
$this
->
all
)
?
'All'
:
optional
(
$this
->
permissions
)
->
pluck
(
'display_name'
),
'permission'
=>
(
$this
->
all
)
?
'All'
:
optional
(
$this
->
permissions
)
->
pluck
(
'display_name'
),
'noofuses'
=>
$this
->
users
->
count
(),
'noofuses'
=>
$this
->
users
->
count
(),
'sort'
=>
$this
->
sort
,
'sort'
=>
$this
->
sort
,
'status'
=>
$this
->
status
'status'
=>
$this
->
status
,
];
];
}
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment