Completed
Push — master ( 39aa91...270cc6 )
by Mahmoud
03:23
created
app/Containers/Application/Data/Factories/ApplicationFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@
 block discarded – undo
4 4
 use App\Containers\Application\Models\Application;
5 5
 use App\Containers\User\Models\User;
6 6
 
7
-$factory->define(Application::class, function (Faker\Generator $faker) {
7
+$factory->define(Application::class, function(Faker\Generator $faker) {
8 8
 
9 9
     return [
10 10
         'name'    => $faker->name,
Please login to merge, or discard this patch.
app/Containers/Socialauth/Tasks/UpdateUserSocialProfileTask.php 1 patch
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -33,12 +33,12 @@
 block discarded – undo
33 33
     /**
34 34
      * @param      $userId
35 35
      * @param null $token
36
-     * @param null $expiresIn
37
-     * @param null $refreshToken
38
-     * @param null $tokenSecret
36
+     * @param boolean|null $expiresIn
37
+     * @param boolean|null $refreshToken
38
+     * @param boolean|null $tokenSecret
39 39
      * @param null $provider
40 40
      * @param null $avatar
41
-     * @param null $avatar_original
41
+     * @param boolean|null $avatar_original
42 42
      * @param null $socialId
43 43
      * @param null $nickname
44 44
      * @param null $name
Please login to merge, or discard this patch.
app/Port/Tests/PHPUnit/Abstracts/TestCase.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
         $this->baseUrl = env('API_FULL_URL'); // this reads the value from `phpunit.xml` during testing
58 58
 
59 59
         // override the default subDomain of the base URL when subDomain property is defined inside a test
60
-        if(property_exists($this, 'subDomain')){
60
+        if (property_exists($this, 'subDomain')) {
61 61
             $this->overrideSubDomain($this->subDomain);
62 62
         }
63 63
 
Please login to merge, or discard this patch.
app/Port/Tests/PHPUnit/Traits/TestingTrait.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -418,7 +418,7 @@
 block discarded – undo
418 418
      */
419 419
     public function overrideSubDomain($subDomain, $url = null)
420 420
     {
421
-        $url = ($url) ? : $this->baseUrl;
421
+        $url = ($url) ?: $this->baseUrl;
422 422
 
423 423
         $info = parse_url($url);
424 424
 
Please login to merge, or discard this patch.
Doc Comments   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     public $loggedInTestingUser;
38 38
 
39 39
     /**
40
-     * @param        $endpoint
40
+     * @param        string $endpoint
41 41
      * @param string $verb
42 42
      * @param array  $data
43 43
      * @param bool   $protected
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
      * So this can be used to test endpoints that are protected by visitors
111 111
      * access.
112 112
      *
113
-     * @return  App\Containers\User\Models\User|mixed
113
+     * @return  User
114 114
      */
115 115
     public function getVisitor()
116 116
     {
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
     }
125 125
 
126 126
     /**
127
-     * @return  App\Containers\User\Models\User|mixed
127
+     * @return  User
128 128
      */
129 129
     public function getLoggedInTestingAdmin()
130 130
     {
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
     /**
163 163
      * @param null $userDetails
164 164
      *
165
-     * @return  mixed
165
+     * @return  User
166 166
      */
167 167
     public function registerAndLoginTestingUser($userDetails = null)
168 168
     {
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
     /**
194 194
      * @param null $userDetails
195 195
      *
196
-     * @return  mixed
196
+     * @return  User
197 197
      */
198 198
     public function registerAndLoginTestingAdmin($userDetails = null)
199 199
     {
@@ -209,7 +209,7 @@  discard block
 block discarded – undo
209 209
      *
210 210
      * @param null $userDetails
211 211
      *
212
-     * @return  mixed
212
+     * @return  User
213 213
      */
214 214
     public function registerAndLoginTestingDeveloper($userDetails = null)
215 215
     {
Please login to merge, or discard this patch.
Data/Migrations/2016_12_29_201047_create_permission_tables.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
     {
15 15
         $config = config('laravel-permission.table_names');
16 16
 
17
-        Schema::create($config['roles'], function (Blueprint $table) {
17
+        Schema::create($config['roles'], function(Blueprint $table) {
18 18
             $table->increments('id');
19 19
             $table->string('name')->unique();
20 20
             $table->string('display_name')->nullable();
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
             $table->timestamps();
23 23
         });
24 24
 
25
-        Schema::create($config['permissions'], function (Blueprint $table) {
25
+        Schema::create($config['permissions'], function(Blueprint $table) {
26 26
             $table->increments('id');
27 27
             $table->string('name')->unique();
28 28
             $table->string('display_name')->nullable();
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
             $table->timestamps();
31 31
         });
32 32
 
33
-        Schema::create($config['user_has_permissions'], function (Blueprint $table) use ($config) {
33
+        Schema::create($config['user_has_permissions'], function(Blueprint $table) use ($config) {
34 34
             $table->integer('user_id')->unsigned();
35 35
             $table->integer('permission_id')->unsigned();
36 36
 
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
             $table->primary(['user_id', 'permission_id']);
48 48
         });
49 49
 
50
-        Schema::create($config['user_has_roles'], function (Blueprint $table) use ($config) {
50
+        Schema::create($config['user_has_roles'], function(Blueprint $table) use ($config) {
51 51
             $table->integer('role_id')->unsigned();
52 52
             $table->integer('user_id')->unsigned();
53 53
 
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
             $table->primary(['role_id', 'user_id']);
65 65
         });
66 66
 
67
-        Schema::create($config['role_has_permissions'], function (Blueprint $table) use ($config) {
67
+        Schema::create($config['role_has_permissions'], function(Blueprint $table) use ($config) {
68 68
             $table->integer('permission_id')->unsigned();
69 69
             $table->integer('role_id')->unsigned();
70 70
 
Please login to merge, or discard this patch.
app/Containers/Authorization/Tasks/AssignRoleTask.php 2 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
                 $this->attachRole($user, $role);
44 44
             }
45 45
 
46
-        }else{
46
+        } else{
47 47
             $this->attachRole($user, $roles);
48 48
         }
49 49
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
      */
46 46
     public function run($user, $roles)
47 47
     {
48
-        if(!$user instanceof User){
48
+        if (!$user instanceof User) {
49 49
             $user = $this->findUserByIdTask->run($user);
50 50
         }
51 51
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
                 $this->assignRole($user, $role);
55 55
             }
56 56
 
57
-        }else{
57
+        } else {
58 58
             $this->assignRole($user, $roles);
59 59
         }
60 60
 
Please login to merge, or discard this patch.
app/Containers/Authorization/UI/API/Tests/Functional/FindRoleByNameTest.php 1 patch
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,7 @@
 block discarded – undo
3 3
 namespace App\Containers\Order\UI\API\Tests\Functional;
4 4
 
5 5
 use App\Containers\Order\Models\Order;
6
-use App\Containers\Invoice\Models\Invoice;
7
-use App\Containers\User\Models\User;
8 6
 use App\Port\Tests\PHPUnit\Abstracts\TestCase;
9
-use Vinkla\Hashids\Facades\Hashids;
10 7
 
11 8
 /**
12 9
  * Class FindRoleByNameTest.
Please login to merge, or discard this patch.
app/Containers/Authorization/UI/API/Tests/Functional/ListRolesTest.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace App\Containers\Authorization\UI\API\Tests\Functional;
4 4
 
5
-use App\Containers\Authorization\Models\User;
6 5
 use App\Port\Tests\PHPUnit\Abstracts\TestCase;
7 6
 
8 7
 /**
Please login to merge, or discard this patch.
app/Containers/User/Actions/CreateUserAction.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
         // be default give all users the client role (normal user)
68 68
         $this->assignRoleTask->run($user, ['client']);
69 69
 
70
-       //  add Client as role for normal users
70
+        //  add Client as role for normal users
71 71
         $this->fireUserCreatedEventTask->run($user);
72 72
 
73 73
         return $user;
Please login to merge, or discard this patch.