Update Routing.php

This commit is contained in:
Visman 2020-06-05 19:32:52 +07:00
parent 37984c50ba
commit 8f63f73fa9

View file

@ -154,8 +154,10 @@ class Routing
$r->add(self::GET, '/admin/bans/delete/{id:[1-9]\d*}/{token}[/{uid:[2-9]|[1-9]\d+}]', 'AdminBans:delete', 'AdminBansDelete');
}
$r->add(self::GET, '/admin/reports', 'AdminReports:view', 'AdminReports');
$r->add(self::GET, '/admin/reports/zap/{id:[1-9]\d*}/{token}', 'AdminReports:zap', 'AdminReportsZap');
if ($user->isAdmin || $config->o_report_method == '0' || $config->o_report_method == '2') {
$r->add(self::GET, '/admin/reports', 'AdminReports:view', 'AdminReports');
$r->add(self::GET, '/admin/reports/zap/{id:[1-9]\d*}/{token}', 'AdminReports:zap', 'AdminReportsZap');
}
}
// только админ
if ($user->isAdmin) {