Skip to content

Commit 74f2344

Browse files
committed
Remove privilege check on news categories
1 parent 9005435 commit 74f2344

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

src/controllers/News/Create.php

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,13 @@ public function run(Router &$router) {
3939
$model->user->getOptionsBitmask() & User::OPTION_ACL_NEWS_CREATE
4040
);
4141

42-
if ($model->acl_allowed) {
43-
$model->news_categories = NewsCategory::getAll();
44-
usort($model->news_categories, function($a, $b){
45-
$oA = $a->getSortId();
46-
$oB = $b->getSortId();
47-
if ($oA == $oB) return 0;
48-
return ($oA < $oB) ? -1 : 1;
49-
});
50-
}
42+
$model->news_categories = NewsCategory::getAll();
43+
usort($model->news_categories, function($a, $b){
44+
$oA = $a->getSortId();
45+
$oB = $b->getSortId();
46+
if ($oA == $oB) return 0;
47+
return ($oA < $oB) ? -1 : 1;
48+
});
5149

5250
if ($router->getRequestMethod() == "POST") {
5351
$this->handlePost($router, $model);

0 commit comments

Comments
 (0)