File tree Expand file tree Collapse file tree 16 files changed +19
-19
lines changed
Expand file tree Collapse file tree 16 files changed +19
-19
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ public function __construct()
2222 translate ('admin/bans ' );
2323 translate ('admin/common ' );
2424
25- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'mod.bans ' )) {
25+ if (!User:: can ('mod.bans ' )) {
2626 throw new Error (__ ('No permission ' ), '403 ' );
2727 }
2828 }
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ public function __construct()
2121 {
2222 $ this ->model = new \FeatherBB \Model \Admin \Categories ();
2323 translate ('admin/categories ' );
24- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.categories ' )) {
24+ if (!User:: can ('board.categories ' )) {
2525 throw new Error (__ ('No permission ' ), '403 ' );
2626 }
2727 }
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public function __construct()
1818 {
1919 $ this ->model = new \FeatherBB \Model \Admin \Censoring ();
2020 translate ('admin/censoring ' );
21- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.censoring ' )) {
21+ if (!User:: can ('board.censoring ' )) {
2222 throw new Error (__ ('No permission ' ), '403 ' );
2323 }
2424 }
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ public function __construct()
2020 {
2121 $ this ->model = new \FeatherBB \Model \Admin \Forums ();
2222 translate ('admin/forums ' );
23- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.forums ' )) {
23+ if (!User:: can ('board.forums ' )) {
2424 throw new Error (__ ('No permission ' ), '403 ' );
2525 }
2626 }
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ public function __construct()
1919 {
2020 $ this ->model = new \FeatherBB \Model \Admin \Groups ();
2121 translate ('admin/groups ' );
22- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.groups ' )) {
22+ if (!User:: can ('board.groups ' )) {
2323 throw new Error (__ ('No permission ' ), '403 ' );
2424 }
2525 }
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ class Index
1919 public function __construct ()
2020 {
2121 translate ('admin/index ' );
22- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'mod.view ' )) {
22+ if (!User:: can ('mod.view ' )) {
2323 throw new Error (__ ('No permission ' ), '403 ' );
2424 }
2525 }
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public function __construct()
1818 {
1919 $ this ->model = new \FeatherBB \Model \Admin \Maintenance ();
2020 translate ('admin/maintenance ' );
21- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.maintenance ' )) {
21+ if (!User:: can ('board.maintenance ' )) {
2222 throw new Error (__ ('No permission ' ), '403 ' );
2323 }
2424 }
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public function __construct()
1818 {
1919 $ this ->model = new \FeatherBB \Model \Admin \Options ();
2020 translate ('admin/options ' );
21- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.options ' )) {
21+ if (!User:: can ('board.options ' )) {
2222 throw new Error (__ ('No permission ' ), '403 ' );
2323 }
2424 }
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ public function __construct()
2020 {
2121 $ this ->model = new \FeatherBB \Model \Admin \Parser ();
2222 translate ('admin/parser ' );
23- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.parser ' )) {
23+ if (!User:: can ('board.parser ' )) {
2424 throw new Error (__ ('No permission ' ), '403 ' );
2525 }
2626 }
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public function __construct()
1818 {
1919 $ this ->model = new \FeatherBB \Model \Admin \Permissions ();
2020 translate ('admin/permissions ' );
21- if (!Container:: get ( ' perms ' )-> can (User:: get (), 'board.permissions ' )) {
21+ if (!User:: can ('board.permissions ' )) {
2222 throw new Error (__ ('No permission ' ), '403 ' );
2323 }
2424 }
You can’t perform that action at this time.
0 commit comments