Skip to content

Commit c1fb0a6

Browse files
DaneEverittStyleCIBot
authored andcommitted
Apply fixes from StyleCI
1 parent a1d3bbf commit c1fb0a6

File tree

150 files changed

+1543
-1745
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

150 files changed

+1543
-1745
lines changed

app/Console/Commands/ClearServices.php

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,10 +21,10 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

2627
use DB;
27-
2828
use Illuminate\Console\Command;
2929

3030
class ClearServices extends Command
@@ -60,8 +60,7 @@ public function __construct()
6060
*/
6161
public function handle()
6262
{
63-
64-
if (!$this->confirm('This is a destructive operation, are you sure you wish to continue?')) {
63+
if (! $this->confirm('This is a destructive operation, are you sure you wish to continue?')) {
6564
$this->error('Canceling.');
6665
exit();
6766
}

app/Console/Commands/ClearTasks.php

+2-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,19 +21,16 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

26-
use DB;
2727
use Carbon;
2828
use Pterodactyl\Models;
2929
use Illuminate\Console\Command;
3030
use Illuminate\Foundation\Bus\DispatchesJobs;
3131

32-
use Pterodactyl\Jobs\SendScheduledTask;
33-
3432
class ClearTasks extends Command
3533
{
36-
3734
use DispatchesJobs;
3835

3936
/**

app/Console/Commands/Inspire.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,6 @@ class Inspire extends Command
2828
*/
2929
public function handle()
3030
{
31-
$this->comment(PHP_EOL.Inspiring::quote().PHP_EOL);
31+
$this->comment(PHP_EOL . Inspiring::quote() . PHP_EOL);
3232
}
3333
}

app/Console/Commands/MakeUser.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,11 +21,10 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

26-
use Hash;
2727
use Illuminate\Console\Command;
28-
2928
use Pterodactyl\Repositories\UserRepository;
3029

3130
class MakeUser extends Command
@@ -77,6 +76,7 @@ public function handle()
7776
try {
7877
$user = new UserRepository;
7978
$user->create($email, $password, $admin);
79+
8080
return $this->info('User successfully created.');
8181
} catch (\Exception $ex) {
8282
return $this->error($ex->getMessage());

app/Console/Commands/RunTasks.php

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,19 +21,17 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

26-
use DB;
2727
use Carbon;
2828
use Pterodactyl\Models;
2929
use Illuminate\Console\Command;
30-
use Illuminate\Foundation\Bus\DispatchesJobs;
31-
3230
use Pterodactyl\Jobs\SendScheduledTask;
31+
use Illuminate\Foundation\Bus\DispatchesJobs;
3332

3433
class RunTasks extends Command
3534
{
36-
3735
use DispatchesJobs;
3836

3937
/**

app/Console/Commands/ShowVersion.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,10 +21,11 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

26-
use Illuminate\Console\Command;
2727
use Version;
28+
use Illuminate\Console\Command;
2829

2930
class ShowVersion extends Command
3031
{

app/Console/Commands/UpdateEmailSettings.php

+11-10
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,6 +21,7 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

2627
use Illuminate\Console\Command;
@@ -66,7 +67,7 @@ public function handle()
6667
{
6768
$variables = [];
6869
$file = base_path() . '/.env';
69-
if (!file_exists($file)) {
70+
if (! file_exists($file)) {
7071
$this->error('Missing environment file! It appears that you have not installed this panel correctly.');
7172
exit();
7273
}
@@ -75,35 +76,35 @@ public function handle()
7576

7677
$this->table([
7778
'Option',
78-
'Description'
79+
'Description',
7980
], [
8081
[
8182
'smtp',
82-
'SMTP Server Email'
83+
'SMTP Server Email',
8384
],
8485
[
8586
'mail',
86-
'PHP\'s Internal Mail Server'
87+
'PHP\'s Internal Mail Server',
8788
],
8889
[
8990
'mailgun',
90-
'Mailgun Email Service'
91+
'Mailgun Email Service',
9192
],
9293
[
9394
'mandrill',
94-
'Mandrill Transactional Email Service'
95+
'Mandrill Transactional Email Service',
9596
],
9697
[
9798
'postmark',
98-
'Postmark Transactional Email Service'
99-
]
99+
'Postmark Transactional Email Service',
100+
],
100101
]);
101102
$variables['MAIL_DRIVER'] = is_null($this->option('driver')) ? $this->choice('Which email driver would you like to use?', [
102103
'smtp',
103104
'mail',
104105
'mailgun',
105106
'mandrill',
106-
'postmark'
107+
'postmark',
107108
]) : $this->option('driver');
108109

109110
switch ($variables['MAIL_DRIVER']) {

app/Console/Commands/UpdateEnvironment.php

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,6 +21,7 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Console\Commands;
2526

2627
use Uuid;
@@ -66,23 +67,22 @@ public function __construct()
6667
*/
6768
public function handle()
6869
{
69-
7070
$variables = [];
7171
$file = base_path() . '/.env';
72-
if (!file_exists($file)) {
72+
if (! file_exists($file)) {
7373
$this->error('Missing environment file! It appears that you have not installed this panel correctly.');
7474
exit();
7575
}
7676

7777
$envContents = file_get_contents($file);
7878

7979
$this->info('Simply leave blank and press enter to fields that you do not wish to update.');
80-
if (!env('SERVICE_AUTHOR', false)) {
80+
if (! env('SERVICE_AUTHOR', false)) {
8181
$this->info('No service author set, setting one now.');
8282
$variables['SERVICE_AUTHOR'] = env('SERVICE_AUTHOR', (string) Uuid::generate(4));
8383
}
8484

85-
if (!env('QUEUE_STANDARD', false) || !env('QUEUE_DRIVER', false)) {
85+
if (! env('QUEUE_STANDARD', false) || ! env('QUEUE_DRIVER', false)) {
8686
$this->info('Setting default queue settings.');
8787
$variables['QUEUE_DRIVER'] = env('QUEUE_DRIVER', 'database');
8888
$variables['QUEUE_HIGH'] = env('QUEUE_HIGH', 'high');
@@ -91,25 +91,25 @@ public function handle()
9191
}
9292

9393
if (is_null($this->option('dbhost'))) {
94-
$variables['DB_HOST'] = $this->anticipate('Database Host', [ 'localhost', '127.0.0.1', env('DB_HOST') ], env('DB_HOST'));
94+
$variables['DB_HOST'] = $this->anticipate('Database Host', ['localhost', '127.0.0.1', env('DB_HOST')], env('DB_HOST'));
9595
} else {
9696
$variables['DB_HOST'] = $this->option('dbhost');
9797
}
9898

9999
if (is_null($this->option('dbport'))) {
100-
$variables['DB_PORT'] = $this->anticipate('Database Port', [ 3306, env('DB_PORT') ], env('DB_PORT'));
100+
$variables['DB_PORT'] = $this->anticipate('Database Port', [3306, env('DB_PORT')], env('DB_PORT'));
101101
} else {
102102
$variables['DB_PORT'] = $this->option('dbport');
103103
}
104104

105105
if (is_null($this->option('dbname'))) {
106-
$variables['DB_DATABASE'] = $this->anticipate('Database Name', [ 'pterodactyl', 'homestead', ENV('DB_DATABASE') ], env('DB_DATABASE'));
106+
$variables['DB_DATABASE'] = $this->anticipate('Database Name', ['pterodactyl', 'homestead', ENV('DB_DATABASE')], env('DB_DATABASE'));
107107
} else {
108108
$variables['DB_DATABASE'] = $this->option('dbname');
109109
}
110110

111111
if (is_null($this->option('dbuser'))) {
112-
$variables['DB_USERNAME'] = $this->anticipate('Database Username', [ ENV('DB_DATABASE') ], env('DB_USERNAME'));
112+
$variables['DB_USERNAME'] = $this->anticipate('Database Username', [ENV('DB_DATABASE')], env('DB_USERNAME'));
113113
} else {
114114
$variables['DB_USERNAME'] = $this->option('dbuser');
115115
}

app/Events/ServerDeleted.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,6 +21,7 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Events;
2526

2627
use Illuminate\Queue\SerializesModels;
@@ -40,5 +41,4 @@ public function __construct($id)
4041
{
4142
$this->server = $id;
4243
}
43-
4444
}

app/Exceptions/AccountNotFoundException.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,9 +21,9 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Exceptions;
2526

2627
class AccountNotFoundException extends \Exception
2728
{
28-
2929
}

app/Exceptions/DisplayException.php

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,13 +21,13 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Exceptions;
2526

2627
use Log;
2728

2829
class DisplayException extends \Exception
2930
{
30-
3131
private $_logging = null;
3232

3333
public function __construct($message, $log = null)
@@ -44,5 +44,4 @@ public function getLogging()
4444
{
4545
return $this->_logging;
4646
}
47-
4847
}

app/Exceptions/DisplayValidationException.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
33
* Pterodactyl - Panel
4-
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>
4+
* Copyright (c) 2015 - 2016 Dane Everitt <[email protected]>.
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -21,6 +21,7 @@
2121
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2222
* SOFTWARE.
2323
*/
24+
2425
namespace Pterodactyl\Exceptions;
2526

2627
class DisplayValidationException extends \Exception

0 commit comments

Comments
 (0)