@@ -27,7 +27,7 @@ |
||
27 | 27 | |
28 | 28 | public function serialize() |
29 | 29 | { |
30 | - $mapValue = function ($value) { |
|
30 | + $mapValue = function($value) { |
|
31 | 31 | if ($value instanceof \Serializable) { |
32 | 32 | return $value->serialize(); |
33 | 33 | } |
@@ -48,7 +48,7 @@ |
||
48 | 48 | { |
49 | 49 | $url = $this->getOccurrenceUrl(); |
50 | 50 | return "Status: $this->status\n" . |
51 | - "Body: " . json_encode($this->info) . "\n" . |
|
52 | - "URL: $url"; |
|
51 | + "Body: " . json_encode($this->info) . "\n" . |
|
52 | + "URL: $url"; |
|
53 | 53 | } |
54 | 54 | } |
@@ -284,8 +284,7 @@ discard block |
||
284 | 284 | public function setCustomDataMethod($config) |
285 | 285 | { |
286 | 286 | $this->customDataMethod = isset($config['custom_data_method']) ? |
287 | - $config['custom_data_method'] : |
|
288 | - \Rollbar\Defaults::get()->customDataMethod(); |
|
287 | + $config['custom_data_method'] : \Rollbar\Defaults::get()->customDataMethod(); |
|
289 | 288 | } |
290 | 289 | |
291 | 290 | protected function setFingerprint($config) |
@@ -523,11 +522,10 @@ discard block |
||
523 | 522 | protected function getMessage($toLog, $context) |
524 | 523 | { |
525 | 524 | return new Message( |
526 | - (string)$toLog, |
|
525 | + (string) $toLog, |
|
527 | 526 | $context, |
528 | 527 | $this->sendMessageTrace ? |
529 | - debug_backtrace($this->localVarsDump ? 0 : DEBUG_BACKTRACE_IGNORE_ARGS) : |
|
530 | - null |
|
528 | + debug_backtrace($this->localVarsDump ? 0 : DEBUG_BACKTRACE_IGNORE_ARGS) : null |
|
531 | 529 | ); |
532 | 530 | } |
533 | 531 | |
@@ -958,8 +956,7 @@ discard block |
||
958 | 956 | |
959 | 957 | if ($customDataMethod = $this->getCustomDataMethod()) { |
960 | 958 | $customDataMethodContext = isset($context['custom_data_method_context']) ? |
961 | - $context['custom_data_method_context'] : |
|
962 | - null; |
|
959 | + $context['custom_data_method_context'] : null; |
|
963 | 960 | |
964 | 961 | $customDataMethodResult = $customDataMethod($toLog, $customDataMethodContext); |
965 | 962 | |
@@ -1125,8 +1122,8 @@ discard block |
||
1125 | 1122 | if ($fatalHandlerMethod || |
1126 | 1123 | $fatalHandlerClassAndFunction || |
1127 | 1124 | $errorHandlerMethod || |
1128 | - $errorHandlerClassAndFunction ) { |
|
1129 | - return array_slice($backTrace, $index+1); |
|
1125 | + $errorHandlerClassAndFunction) { |
|
1126 | + return array_slice($backTrace, $index + 1); |
|
1130 | 1127 | } |
1131 | 1128 | } |
1132 | 1129 |
@@ -106,7 +106,7 @@ |
||
106 | 106 | $truncated = $this->truncate($encoded); |
107 | 107 | |
108 | 108 | $this->debugLogger->info( |
109 | - "Payload scrubbed and ready to send to ". |
|
109 | + "Payload scrubbed and ready to send to " . |
|
110 | 110 | $this->config->getSender()->toString() |
111 | 111 | ); |
112 | 112 | $this->debugLogger->debug($truncated); |
@@ -93,7 +93,7 @@ |
||
93 | 93 | } |
94 | 94 | |
95 | 95 | $scrubber = $this; |
96 | - $scrubberFn = function ( |
|
96 | + $scrubberFn = function( |
|
97 | 97 | &$val, |
98 | 98 | $key |
99 | 99 | ) use ( |
@@ -92,7 +92,7 @@ |
||
92 | 92 | if (is_null(self::$logger)) { |
93 | 93 | return self::getNotInitializedResponse(); |
94 | 94 | } |
95 | - return self::$logger->log($level, $toLog, (array)$extra, $isUncaught); |
|
95 | + return self::$logger->log($level, $toLog, (array) $extra, $isUncaught); |
|
96 | 96 | } |
97 | 97 | |
98 | 98 | public static function debug($toLog, $extra = array()) |
@@ -808,7 +808,7 @@ |
||
808 | 808 | |
809 | 809 | public function wait($accessToken, $max = 0) |
810 | 810 | { |
811 | - $this->sender->wait($accessToken, $max); |
|
811 | + $this->sender->wait($accessToken, $max); |
|
812 | 812 | } |
813 | 813 | |
814 | 814 | public function handleResponse($payload, $response) |
@@ -7,7 +7,7 @@ discard block |
||
7 | 7 | if (!defined('ROLLBAR_INCLUDED_ERRNO_BITMASK')) { |
8 | 8 | define( |
9 | 9 | 'ROLLBAR_INCLUDED_ERRNO_BITMASK', |
10 | - E_ERROR | E_WARNING | E_PARSE | E_CORE_ERROR | E_USER_ERROR | E_RECOVERABLE_ERROR |
|
10 | + E_ERROR|E_WARNING|E_PARSE|E_CORE_ERROR|E_USER_ERROR|E_RECOVERABLE_ERROR |
|
11 | 11 | ); |
12 | 12 | } |
13 | 13 | |
@@ -536,8 +536,7 @@ discard block |
||
536 | 536 | $options = $config; |
537 | 537 | } else { |
538 | 538 | $options = isset($config[$keyName . "Options"]) ? |
539 | - $config[$keyName . "Options"] : |
|
540 | - array(); |
|
539 | + $config[$keyName . "Options"] : array(); |
|
541 | 540 | } |
542 | 541 | $this->$keyName = new $$keyName($options); |
543 | 542 | } else { |
@@ -598,7 +597,7 @@ discard block |
||
598 | 597 | if (count($this->custom) > 0) { |
599 | 598 | $data = $payload->getData(); |
600 | 599 | $custom = $data->getCustom(); |
601 | - $custom = array_merge(array(), $this->custom, (array)$custom); |
|
600 | + $custom = array_merge(array(), $this->custom, (array) $custom); |
|
602 | 601 | $data->setCustom($custom); |
603 | 602 | $payload->setData($data); |
604 | 603 | } |
@@ -683,12 +682,12 @@ discard block |
||
683 | 682 | */ |
684 | 683 | public function shouldIgnoreError($errno) |
685 | 684 | { |
686 | - if ($this->useErrorReporting && ($errno & error_reporting()) === 0) { |
|
685 | + if ($this->useErrorReporting && ($errno&error_reporting()) === 0) { |
|
687 | 686 | // ignore due to error_reporting level |
688 | 687 | return true; |
689 | 688 | } |
690 | 689 | |
691 | - if ($this->includedErrno != -1 && ($errno & $this->includedErrno) != $errno) { |
|
690 | + if ($this->includedErrno != -1 && ($errno&$this->includedErrno) != $errno) { |
|
692 | 691 | // ignore |
693 | 692 | return true; |
694 | 693 | } |
@@ -759,7 +758,7 @@ discard block |
||
759 | 758 | |
760 | 759 | $class = get_class($toLog); |
761 | 760 | while ($class) { |
762 | - $exceptionClasses []= $class; |
|
761 | + $exceptionClasses [] = $class; |
|
763 | 762 | $class = get_parent_class($class); |
764 | 763 | } |
765 | 764 | $exceptionClasses = array_reverse($exceptionClasses); |
@@ -66,8 +66,7 @@ discard block |
||
66 | 66 | $statusCode = curl_getinfo($handle, CURLINFO_HTTP_CODE); |
67 | 67 | |
68 | 68 | $result = $result === false ? |
69 | - curl_error($handle) : |
|
70 | - json_decode($result, true); |
|
69 | + curl_error($handle) : json_decode($result, true); |
|
71 | 70 | |
72 | 71 | curl_close($handle); |
73 | 72 | |
@@ -119,7 +118,7 @@ discard block |
||
119 | 118 | $handle = curl_init(); |
120 | 119 | $this->setCurlOptions($handle, $payload, $accessToken); |
121 | 120 | curl_multi_add_handle($this->multiHandle, $handle); |
122 | - $handleArrayKey = (int)$handle; |
|
121 | + $handleArrayKey = (int) $handle; |
|
123 | 122 | $this->inflightRequests[$handleArrayKey] = true; |
124 | 123 | } |
125 | 124 | $this->batchRequests = array_slice($this->batchRequests, $idx); |
@@ -174,7 +173,7 @@ discard block |
||
174 | 173 | { |
175 | 174 | while ($info = curl_multi_info_read($this->multiHandle)) { |
176 | 175 | $handle = $info['handle']; |
177 | - $handleArrayKey = (int)$handle; |
|
176 | + $handleArrayKey = (int) $handle; |
|
178 | 177 | if (isset($this->inflightRequests[$handleArrayKey])) { |
179 | 178 | unset($this->inflightRequests[$handleArrayKey]); |
180 | 179 | curl_multi_remove_handle($this->multiHandle, $handle); |
@@ -165,7 +165,7 @@ |
||
165 | 165 | if ($headers !== null && $this->shouldAppendNonce($headers)) { |
166 | 166 | if (!$nonce) { |
167 | 167 | throw new \Exception( |
168 | - 'Content-Security-Policy is script-src '. |
|
168 | + 'Content-Security-Policy is script-src ' . |
|
169 | 169 | 'inline-unsafe but nonce value not provided.' |
170 | 170 | ); |
171 | 171 | } |