| Total Complexity | 13 |
| Total Lines | 53 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | class UrlAlias |
||
| 12 | { |
||
| 13 | protected $app; |
||
| 14 | |||
| 15 | protected $config; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * UrlAlias constructor. |
||
| 19 | * |
||
| 20 | * @param $app |
||
| 21 | * @throws \Exception |
||
| 22 | */ |
||
| 23 | public function __construct($app = null) |
||
| 24 | { |
||
| 25 | if (!$app) { |
||
| 26 | $app = app(); //Fallback when $app is not given |
||
|
|
|||
| 27 | } |
||
| 28 | $this->app = $app; |
||
| 29 | |||
| 30 | $this->config = $this->app['config']; |
||
| 31 | } |
||
| 32 | |||
| 33 | public function route(string $systemName, $parameters = [], $absolute = true, $forceWithLocalePreffix = false): string |
||
| 57 | } |
||
| 58 | |||
| 59 | public function current($absolute = true): string |
||
| 64 | } |
||
| 65 | } |