File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ public function store(CreateRoleRequest $request) : RedirectResponse
43
43
public function edit ($ name ) : View
44
44
{
45
45
$ role = (new Role )->with ('permissions ' )->find ($ name );
46
- $ this ->authorize ($ role );
46
+ $ this ->authorize (' edit ' , $ role );
47
47
$ entities = (new Entity )->whereNotIn ('name ' , ['permission ' , 'entity ' ])->get ();
48
48
$ actions = (new Action )->all ();
49
49
$ ownerships = (new Ownership )->all ();
@@ -73,6 +73,7 @@ public function edit($name) : View
73
73
public function update (UpdateRoleRequest $ request , $ name ) : RedirectResponse
74
74
{
75
75
$ role = (new Role )->find ($ name );
76
+ $ this ->authorize ('edit ' , $ role );
76
77
$ role ->fill ($ request ->only (['name ' , 'description ' ]));
77
78
78
79
if ($ request ->has ('permissions ' )) {
You can’t perform that action at this time.
0 commit comments