@@ -2,7 +2,8 @@ |
||
2 | 2 | use App\Model\Role; |
3 | 3 | use App\Model\User; |
4 | 4 | |
5 | -class CreateRolesRightsUsers { |
|
5 | +class CreateRolesRightsUsers |
|
6 | +{ |
|
6 | 7 | public function run() |
7 | 8 | { |
8 | 9 | Role::create([ |
@@ -12,8 +12,8 @@ |
||
12 | 12 | |
13 | 13 | public function actionIndex() |
14 | 14 | { |
15 | - echo 'This is sample console command.' . PHP_EOL; |
|
16 | - echo 'Actions: ' . PHP_EOL; |
|
17 | - echo 'partisan sample index' . PHP_EOL; |
|
15 | + echo 'This is sample console command.'.PHP_EOL; |
|
16 | + echo 'Actions: '.PHP_EOL; |
|
17 | + echo 'partisan sample index'.PHP_EOL; |
|
18 | 18 | } |
19 | 19 | } |
@@ -111,7 +111,7 @@ |
||
111 | 111 | * @param Response $response |
112 | 112 | * @param array $args |
113 | 113 | * |
114 | - * @return mixed |
|
114 | + * @return \Psr\Http\Message\ResponseInterface |
|
115 | 115 | * @throws JsonException |
116 | 116 | */ |
117 | 117 | public function actionCreate(Request $request, Response $response, $args) |
@@ -45,7 +45,7 @@ |
||
45 | 45 | $query = $query->whereNotIn($filter['attribute'], $filter['value']); |
46 | 46 | break; |
47 | 47 | case 'like': |
48 | - $query = $query->where($filter['attribute'], 'like', '%'.$filter['value'] . '%'); |
|
48 | + $query = $query->where($filter['attribute'], 'like', '%'.$filter['value'].'%'); |
|
49 | 49 | break; |
50 | 50 | case '=': |
51 | 51 | case '!=': |
@@ -20,7 +20,8 @@ |
||
20 | 20 | /** |
21 | 21 | * Undo the migration |
22 | 22 | */ |
23 | - public function down() { |
|
23 | + public function down() |
|
24 | + { |
|
24 | 25 | Capsule::schema()->drop('refresh_tokens'); |
25 | 26 | } |
26 | 27 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | */ |
15 | 15 | public function register(Container $container) |
16 | 16 | { |
17 | - $config = $container['settings']; |
|
17 | + $config = $container['settings']; |
|
18 | 18 | |
19 | 19 | $container['encoder'] = function() use ($config) { |
20 | 20 | $encoder = new JsonApiEncoder($config); |
@@ -67,7 +67,7 @@ |
||
67 | 67 | * @param string $template |
68 | 68 | * @param array $data |
69 | 69 | */ |
70 | - protected function protectedIncludeScope ($template, array $data) |
|
70 | + protected function protectedIncludeScope($template, array $data) |
|
71 | 71 | { |
72 | 72 | extract($data); |
73 | 73 | include $template; |
@@ -100,7 +100,7 @@ |
||
100 | 100 | |
101 | 101 | foreach ($observers as $observer => $models) { |
102 | 102 | foreach ($models as $model) { |
103 | - call_user_func($model. '::observe', $observer); |
|
103 | + call_user_func($model.'::observe', $observer); |
|
104 | 104 | } |
105 | 105 | } |
106 | 106 | } |
@@ -68,7 +68,7 @@ |
||
68 | 68 | |
69 | 69 | /** |
70 | 70 | * @param User $user |
71 | - * @param $host |
|
71 | + * @param string $host |
|
72 | 72 | * @param array $settings |
73 | 73 | * |
74 | 74 | * @return string |
@@ -1,10 +1,10 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | 3 | // PATH aliases |
4 | -define('ROOT_PATH', __DIR__ ); |
|
5 | -define('MIGRATIONS_PATH', __DIR__ . '/app/database/migrations'); |
|
6 | -define('SEEDS_PATH', __DIR__ . '/app/database/seeds'); |
|
7 | -define('COMMANDS_PATH', __DIR__ . '/app/src/Commands'); |
|
8 | -define('CONFIG_PATH', __DIR__ . '/config'); |
|
9 | -define('APP_PATH', __DIR__ . '/app'); |
|
4 | +define('ROOT_PATH', __DIR__); |
|
5 | +define('MIGRATIONS_PATH', __DIR__.'/app/database/migrations'); |
|
6 | +define('SEEDS_PATH', __DIR__.'/app/database/seeds'); |
|
7 | +define('COMMANDS_PATH', __DIR__.'/app/src/Commands'); |
|
8 | +define('CONFIG_PATH', __DIR__.'/config'); |
|
9 | +define('APP_PATH', __DIR__.'/app'); |
|
10 | 10 |