@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | { |
10 | 10 | public function up(): void |
11 | 11 | { |
12 | - //Action when migrate up |
|
12 | + //Action when migrate up |
|
13 | 13 | $this->create('roles_users', function (CreateTable $table) { |
14 | 14 | $table->integer('user_id'); |
15 | 15 | $table->integer('role_id'); |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | |
31 | 31 | public function down(): void |
32 | 32 | { |
33 | - //Action when migrate down |
|
33 | + //Action when migrate down |
|
34 | 34 | $this->drop('roles_users'); |
35 | 35 | } |
36 | 36 | } |
@@ -10,7 +10,7 @@ |
||
10 | 10 | public function up(): void |
11 | 11 | { |
12 | 12 | //Action when migrate up |
13 | - $this->create('roles_users', function (CreateTable $table) { |
|
13 | + $this->create('roles_users', function(CreateTable $table) { |
|
14 | 14 | $table->integer('user_id'); |
15 | 15 | $table->integer('role_id'); |
16 | 16 |
@@ -5,12 +5,11 @@ |
||
5 | 5 | use Platine\Database\Schema\CreateTable; |
6 | 6 | use Platine\Framework\Migration\AbstractMigration; |
7 | 7 | |
8 | -class AddRoleUsersTable20210717100434 extends AbstractMigration |
|
9 | -{ |
|
8 | +class AddRoleUsersTable20210717100434 extends AbstractMigration { |
|
10 | 9 | public function up(): void |
11 | 10 | { |
12 | 11 | //Action when migrate up |
13 | - $this->create('roles_users', function (CreateTable $table) { |
|
12 | + $this->create('roles_users', function (CreateTable $table) { |
|
14 | 13 | $table->integer('user_id'); |
15 | 14 | $table->integer('role_id'); |
16 | 15 |
@@ -55,8 +55,7 @@ |
||
55 | 55 | * @class ConsoleServiceProvider |
56 | 56 | * @package Platine\App\Provider |
57 | 57 | */ |
58 | -class ConsoleServiceProvider extends ServiceProvider |
|
59 | -{ |
|
58 | +class ConsoleServiceProvider extends ServiceProvider { |
|
60 | 59 | /** |
61 | 60 | * {@inheritdoc} |
62 | 61 | */ |
@@ -55,8 +55,7 @@ |
||
55 | 55 | * @class AppServiceProvider |
56 | 56 | * @package Platine\App\Provider |
57 | 57 | */ |
58 | -class AppServiceProvider extends ServiceProvider |
|
59 | -{ |
|
58 | +class AppServiceProvider extends ServiceProvider { |
|
60 | 59 | /** |
61 | 60 | * {@inheritdoc} |
62 | 61 | */ |
@@ -57,8 +57,7 @@ discard block |
||
57 | 57 | * @class HomeAction |
58 | 58 | * @package Platine\App\Http\Action |
59 | 59 | */ |
60 | -class HomeAction implements RequestHandlerInterface |
|
61 | -{ |
|
60 | +class HomeAction implements RequestHandlerInterface { |
|
62 | 61 | /** |
63 | 62 | * The template instance |
64 | 63 | * @var Template |
@@ -69,8 +68,7 @@ discard block |
||
69 | 68 | * Create new instance |
70 | 69 | * @param Template $template |
71 | 70 | */ |
72 | - public function __construct(Template $template) |
|
73 | - { |
|
71 | + public function __construct(Template $template) { |
|
74 | 72 | $this->template = $template; |
75 | 73 | } |
76 | 74 |
@@ -54,8 +54,7 @@ discard block |
||
54 | 54 | * @class ServerCommand |
55 | 55 | * @package Platine\App\Console\Command |
56 | 56 | */ |
57 | -class ServerCommand extends Command |
|
58 | -{ |
|
57 | +class ServerCommand extends Command { |
|
59 | 58 | /** |
60 | 59 | * The shell instance to use |
61 | 60 | * @var Shell |
@@ -66,8 +65,7 @@ discard block |
||
66 | 65 | * Create new instance |
67 | 66 | * {@inheritdoc} |
68 | 67 | */ |
69 | - public function __construct(Shell $shell) |
|
70 | - { |
|
68 | + public function __construct(Shell $shell) { |
|
71 | 69 | parent::__construct('server', 'Command to manage PHP development server'); |
72 | 70 | $this->addOption('-a|--address', 'Server address', '0.0.0.0', true); |
73 | 71 | $this->addOption('-p|--port', 'Server listen port', '8080', true); |
@@ -79,8 +77,7 @@ discard block |
||
79 | 77 | /** |
80 | 78 | * {@inheritdoc} |
81 | 79 | */ |
82 | - public function execute() |
|
83 | - { |
|
80 | + public function execute() { |
|
84 | 81 | $host = $this->getOptionValue('address'); |
85 | 82 | $port = $this->getOptionValue('port'); |
86 | 83 | $path = $this->getOptionValue('root'); |
@@ -92,7 +89,7 @@ discard block |
||
92 | 89 | |
93 | 90 | $this->shell->execute(true); |
94 | 91 | $writer->boldWhite($this->shell->getOutput(), true); |
95 | - if ($this->shell->getExitCode() !== 0) { |
|
92 | + if ($this->shell->getExitCode() !== 0) { |
|
96 | 93 | $writer->boldRed($this->shell->getErrorOutput(), true); |
97 | 94 | } |
98 | 95 | } |
@@ -39,6 +39,5 @@ |
||
39 | 39 | * @class ApplicationException |
40 | 40 | * @package Platine\App\Exception |
41 | 41 | */ |
42 | -class ApplicationException extends Exception |
|
43 | -{ |
|
42 | +class ApplicationException extends Exception { |
|
44 | 43 | } |