1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-06 05:07:36 +02:00

Fix CS and php5.3 compat

This commit is contained in:
Jordi Boggiano
2015-08-31 10:26:07 +01:00
parent 0524c87587
commit 5785a9ac4a
4 changed files with 4 additions and 7 deletions

View File

@@ -33,13 +33,11 @@ class Util
{ {
while ($retries--) { while ($retries--) {
if (curl_exec($ch) === false) { if (curl_exec($ch) === false) {
$curlErrno = curl_errno($ch); $curlErrno = curl_errno($ch);
if (false === in_array($curlErrno, self::$retriableErrorCodes, true) || !$retries) { if (false === in_array($curlErrno, self::$retriableErrorCodes, true) || !$retries) {
$curlError = curl_error($ch); $curlError = curl_error($ch);
if ($closeAfterDone) { if ($closeAfterDone) {
curl_close($ch); curl_close($ch);
} }

View File

@@ -58,7 +58,7 @@ class RollbarHandler extends AbstractProcessingHandler
$exception = $context['exception']; $exception = $context['exception'];
unset($context['exception']); unset($context['exception']);
$payload = []; $payload = array();
if (isset($context['payload'])) { if (isset($context['payload'])) {
$payload = $context['payload']; $payload = $context['payload'];
unset($context['payload']); unset($context['payload']);

View File

@@ -91,7 +91,7 @@ class IntrospectionProcessor
return $record; return $record;
} }
private function isTraceClassOrSkippedFunction (array $trace, $index) private function isTraceClassOrSkippedFunction(array $trace, $index)
{ {
if (!isset($trace[$index])) { if (!isset($trace[$index])) {
return false; return false;

View File

@@ -130,7 +130,6 @@ class RegistryTest extends \PHPUnit_Framework_TestCase
$log1 = new Logger('test1'); $log1 = new Logger('test1');
$log2 = new Logger('test2'); $log2 = new Logger('test2');
Registry::addLogger($log1, 'log'); Registry::addLogger($log1, 'log');
Registry::addLogger($log2, 'log', true); Registry::addLogger($log2, 'log', true);