GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Push — master ( c28c6c...173d59 )
by Steeven
02:19
created
src/Http/Controllers/Restful.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -288,7 +288,7 @@  discard block
 block discarded – undo
288 288
      */
289 289
     public function index()
290 290
     {
291
-        if(empty($this->model)) {
291
+        if (empty($this->model)) {
292 292
             output()->sendError(204);
293 293
         } else {
294 294
             if ( ! $this->model instanceof Model) {
@@ -350,9 +350,9 @@  discard block
 block discarded – undo
350 350
             if (is_numeric(key($code))) {
351 351
                 $message = reset($code);
352 352
                 $code = key($code);
353
-            } elseif (isset($code[ 'code' ])) {
354
-                $code = $code[ 'code' ];
355
-                $message = $code[ 'message' ];
353
+            } elseif (isset($code['code'])) {
354
+                $code = $code['code'];
355
+                $message = $code['message'];
356 356
             }
357 357
         }
358 358
 
@@ -420,7 +420,7 @@  discard block
 block discarded – undo
420 420
                 $longPoolingCacheMetadata = $longPoolingCacheData->getMetadata();
421 421
 
422 422
                 // if no timestamp delivered via ajax or data.txt has been changed SINCE last ajax timestamp
423
-                if ($lastCallTimestamp == null || $longPoolingCacheMetadata[ 'ctime' ] > $lastCallTimestamp) {
423
+                if ($lastCallTimestamp == null || $longPoolingCacheMetadata['ctime'] > $lastCallTimestamp) {
424 424
                     output()->send([
425 425
                         'timestamp' => $longPoolingCacheMetadata,
426 426
                         'data'      => $data,
@@ -461,14 +461,14 @@  discard block
 block discarded – undo
461 461
 
462 462
             if (count($this->fillableColumnsWithRules)) {
463 463
                 foreach ($this->fillableColumnsWithRules as $column) {
464
-                    if ($post->offsetExists($column[ 'field' ])) {
465
-                        $data[ $column[ 'field' ] ] = $post->offsetGet($column[ 'field' ]);
464
+                    if ($post->offsetExists($column['field'])) {
465
+                        $data[$column['field']] = $post->offsetGet($column['field']);
466 466
                     }
467 467
                 }
468 468
             } elseif (count($this->fillableColumns)) {
469 469
                 foreach ($this->fillableColumns as $column) {
470
-                    if ($post->offsetExists($column[ 'field' ])) {
471
-                        $data[ $column[ 'field' ] ] = $post->offsetGet($column[ 'field' ]);
470
+                    if ($post->offsetExists($column['field'])) {
471
+                        $data[$column['field']] = $post->offsetGet($column['field']);
472 472
                     }
473 473
                 }
474 474
             } else {
@@ -476,11 +476,11 @@  discard block
 block discarded – undo
476 476
             }
477 477
 
478 478
             if (count($data)) {
479
-                $data[ 'record_create_timestamp' ] = $data[ 'record_update_timestamp' ] = timestamp();
480
-                $data[ 'record_create_user' ] = $data[ 'record_update_user' ] = globals()->account->id;
479
+                $data['record_create_timestamp'] = $data['record_update_timestamp'] = timestamp();
480
+                $data['record_create_user'] = $data['record_update_user'] = globals()->account->id;
481 481
 
482 482
                 if ($this->model->insert($data)) {
483
-                    $data[ 'id' ] = $this->model->db->getLastInsertId();
483
+                    $data['id'] = $this->model->db->getLastInsertId();
484 484
                     $this->sendPayload([
485 485
                         'code' => 201,
486 486
                         'Successful insert request',
@@ -526,14 +526,14 @@  discard block
 block discarded – undo
526 526
 
527 527
             if (count($this->fillableColumnsWithRules)) {
528 528
                 foreach ($this->fillableColumnsWithRules as $column) {
529
-                    if ($post->offsetExists($column[ 'field' ])) {
530
-                        $data[ $column[ 'field' ] ] = $post->offsetGet($column[ 'field' ]);
529
+                    if ($post->offsetExists($column['field'])) {
530
+                        $data[$column['field']] = $post->offsetGet($column['field']);
531 531
                     }
532 532
                 }
533 533
             } elseif (count($this->fillableColumns)) {
534 534
                 foreach ($this->fillableColumns as $column) {
535
-                    if ($post->offsetExists($column[ 'field' ])) {
536
-                        $data[ $column[ 'field' ] ] = $post->offsetGet($column[ 'field' ]);
535
+                    if ($post->offsetExists($column['field'])) {
536
+                        $data[$column['field']] = $post->offsetGet($column['field']);
537 537
                     }
538 538
                 }
539 539
             } else {
@@ -541,8 +541,8 @@  discard block
 block discarded – undo
541 541
             }
542 542
 
543 543
             if (count($data)) {
544
-                $data[ 'record_update_timestamp' ] = timestamp();
545
-                $data[ 'record_update_user' ] = globals()->account->id;
544
+                $data['record_update_timestamp'] = timestamp();
545
+                $data['record_update_user'] = globals()->account->id;
546 546
 
547 547
                 if ($this->model->update($data)) {
548 548
                     $this->sendError(201, 'Successful update request');
Please login to merge, or discard this patch.