Skip to content

Commit 13e2356

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents 12e77e0 + c9cbd41 commit 13e2356

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

README.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -101,16 +101,18 @@ Configuring guards is very simple. Your module's config would look like so:
101101
'user' => [
102102
'guards' => [
103103
'ModuleName' => [
104-
\Application\Controller\IndexController::class => [
105-
'default' => [], // anyone can access
106-
],
107-
\Application\Controller\MemberController::class => [
108-
'default' => ['user'], // specific role access
109-
],
110-
\Application\Controller\AdminController::class => [
111-
'default' => ['admin'],
112-
'actions' => [ // action-level guards
113-
'list' => [ 'user' ], // role 'user' can access 'listAction' on AdminController
104+
"controllers" => [
105+
\Application\Controller\IndexController::class => [
106+
'default' => [], // anyone can access
107+
],
108+
\Application\Controller\MemberController::class => [
109+
'default' => ['user'], // specific role access
110+
],
111+
\Application\Controller\AdminController::class => [
112+
'default' => ['admin'],
113+
'actions' => [ // action-level guards
114+
'list' => [ 'user' ], // role 'user' can access 'listAction' on AdminController
115+
],
114116
],
115117
],
116118
],

0 commit comments

Comments
 (0)