Passed
Push — develop ( b61819...d8654a )
by nguereza
03:06
created
src/Auth/Entity/Token.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
             'updated_at' => '?date',
71 71
         ]);
72 72
         
73
-        $mapper->filter('not_expire', function (Query $q, $date) {
73
+        $mapper->filter('not_expire', function(Query $q, $date) {
74 74
             $q->where('expire_at')->gt($date);
75 75
         });
76 76
     }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -55,8 +55,7 @@
 block discarded – undo
55 55
  * @class Token
56 56
  * @package Platine\Framework\Auth\Entity
57 57
  */
58
-class Token extends Entity
59
-{
58
+class Token extends Entity {
60 59
     /**
61 60
      * {@inheritdoc}
62 61
      */
Please login to merge, or discard this patch.
src/Auth/Authentication/JWTAuthentication.php 2 patches
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -249,11 +249,11 @@  discard block
 block discarded – undo
249 249
         $tokenExpire = time() + $expire;
250 250
         $refreshTokenExpire = time() + $refreshExpire;
251 251
         $this->jwt->setSecret($secret)
252
-                  ->setPayload([
253
-                      'sub' => $user->id,
254
-                      'exp' => $tokenExpire,
255
-                  ])
256
-                  ->sign();
252
+                    ->setPayload([
253
+                        'sub' => $user->id,
254
+                        'exp' => $tokenExpire,
255
+                    ])
256
+                    ->sign();
257 257
         $refreshToken = Str::randomToken(24);
258 258
         $jwtToken = $this->jwt->getToken();
259 259
 
@@ -267,16 +267,16 @@  discard block
 block discarded – undo
267 267
         $this->tokenRepository->save($token);
268 268
 
269 269
         $data = [
270
-          'user' => [
270
+            'user' => [
271 271
             'id' => $user->id,
272 272
             'username' => $user->username,
273 273
             'lastname' => $user->lastname,
274 274
             'firstname' => $user->firstname,
275 275
             'email' => $user->email,
276 276
             'permissions' => $permissions,
277
-          ],
278
-          'token' => $jwtToken,
279
-          'refresh_token' => $refreshToken,
277
+            ],
278
+            'token' => $jwtToken,
279
+            'refresh_token' => $refreshToken,
280 280
         ];
281 281
 
282 282
         return $data;
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -69,8 +69,7 @@
 block discarded – undo
69 69
  * @package Platine\Framework\Auth\Authentication
70 70
  * @template T
71 71
  */
72
-class JWTAuthentication implements ApiAuthenticationInterface
73
-{
72
+class JWTAuthentication implements ApiAuthenticationInterface {
74 73
     /**
75 74
      * The JWT instance
76 75
      * @var JWT
Please login to merge, or discard this patch.
src/Service/Provider/PDFServiceProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@
 block discarded – undo
66 66
      */
67 67
     public function register(): void
68 68
     {
69
-        $this->app->bind(Dompdf::class, function (ContainerInterface $app) {
69
+        $this->app->bind(Dompdf::class, function(ContainerInterface $app) {
70 70
             $defaultOptions = array(
71 71
                 'isRemoteEnabled' => true
72 72
             );
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -58,8 +58,7 @@
 block discarded – undo
58 58
  * @class PDFServiceProvider
59 59
  * @package Platine\Framework\Service\Provider
60 60
  */
61
-class PDFServiceProvider extends ServiceProvider
62
-{
61
+class PDFServiceProvider extends ServiceProvider {
63 62
     /**
64 63
      * {@inheritdoc}
65 64
      */
Please login to merge, or discard this patch.
src/Http/Exception/HttpBadRequestException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@
 block discarded – undo
37 37
  * @class HttpBadRequestException
38 38
  * @package Platine\Framework\Http\Exception
39 39
  */
40
-class HttpBadRequestException extends HttpSpecialException
41
-{
40
+class HttpBadRequestException extends HttpSpecialException {
42 41
     /**
43 42
      *
44 43
      * @var int
Please login to merge, or discard this patch.
src/Http/Exception/HttpForbiddenException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,8 +39,7 @@
 block discarded – undo
39 39
  * @class HttpForbiddenException
40 40
  * @package Platine\Framework\Http\Exception
41 41
  */
42
-class HttpForbiddenException extends HttpSpecialException
43
-{
42
+class HttpForbiddenException extends HttpSpecialException {
44 43
     /**
45 44
      *
46 45
      * @var int
Please login to merge, or discard this patch.
src/Http/Exception/HttpUnauthorizedException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@
 block discarded – undo
37 37
  * @class HttpUnauthorizedException
38 38
  * @package Platine\Framework\Http\Exception
39 39
  */
40
-class HttpUnauthorizedException extends HttpSpecialException
41
-{
40
+class HttpUnauthorizedException extends HttpSpecialException {
42 41
     /**
43 42
      *
44 43
      * @var int
Please login to merge, or discard this patch.
src/Http/Exception/HttpNotImplementedException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@
 block discarded – undo
37 37
  * @class HttpNotImplementedException
38 38
  * @package Platine\Framework\Http\Exception
39 39
  */
40
-class HttpNotImplementedException extends HttpSpecialException
41
-{
40
+class HttpNotImplementedException extends HttpSpecialException {
42 41
     /**
43 42
      *
44 43
      * @var int
Please login to merge, or discard this patch.
src/Http/Exception/HttpInternalServerErrorException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@
 block discarded – undo
37 37
  * @class HttpInternalServerErrorException
38 38
  * @package Platine\Framework\Http\Exception
39 39
  */
40
-class HttpInternalServerErrorException extends HttpSpecialException
41
-{
40
+class HttpInternalServerErrorException extends HttpSpecialException {
42 41
     /**
43 42
      *
44 43
      * @var int
Please login to merge, or discard this patch.
src/Http/Response/RedirectResponse.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -53,15 +53,13 @@
 block discarded – undo
53 53
  * @class RedirectResponse
54 54
  * @package Platine\Framework\Http\Response
55 55
  */
56
-class RedirectResponse extends Response
57
-{
56
+class RedirectResponse extends Response {
58 57
 
59 58
     /**
60 59
      * Create new instance
61 60
      * @param string $url
62 61
      */
63
-    public function __construct(string $url = '/')
64
-    {
62
+    public function __construct(string $url = '/') {
65 63
         parent::__construct(302);
66 64
         $this->headers['location'] = [$url];
67 65
     }
Please login to merge, or discard this patch.