Passed
Push — master ( 656cd4...f7cefd )
by Peter
02:21
created

anonymous()

Size

Total Lines 11
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 7
nc 1
nop 1
dl 0
loc 11
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
use AbterPhp\Admin\Http\Middleware\Authentication;
6
use AbterPhp\Admin\Http\Middleware\Authorization;
7
use AbterPhp\Admin\Http\Middleware\LastGridPage;
8
use AbterPhp\Framework\Authorization\Constant\Role;
9
use AbterPhp\Website\Constant\Routes;
10
use Opulence\Routing\Router;
11
12
/**
13
 * ----------------------------------------------------------
14
 * Create all of the routes for the HTTP kernel
15
 * ----------------------------------------------------------
16
 *
17
 * @var Router $router
18
 */
19
$router->group(
20
    ['controllerNamespace' => 'AbterPhp\Website\Http\Controllers'],
21
    function (Router $router) {
22
        /** @see \AbterPhp\Website\Http\Controllers\Website\Index::homePage() */
23
        $router->get(Routes::PATH_HOME, 'Website\Index@homePage', [OPTION_NAME => Routes::ROUTE_HOME]);
0 ignored issues
show
Bug introduced by
The constant OPTION_NAME was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
24
25
        /** @see \AbterPhp\Website\Http\Controllers\Website\Index::otherPage() */
26
        $router->get(
27
            Routes::PATH_PAGE,
28
            'Website\Index@otherPage',
29
            [
30
                OPTION_NAME => Routes::ROUTE_PAGE_OTHER,
31
                OPTION_VARS => [Routes::VAR_ANYTHING => '[\w\d\-]+'],
0 ignored issues
show
Bug introduced by
The constant OPTION_VARS was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
32
            ]
33
        );
34
    }
35
);
36