forked from LiveCarta/PayPal-PHP-SDK
[PSR] Fixed library source
- Using `php-cs-fixer` tool.
This commit is contained in:
@@ -23,4 +23,4 @@ class PayPalDefaultLogFactory implements PayPalLogFactory
|
||||
{
|
||||
return new PayPalLogger($className);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,5 +13,4 @@ interface PayPalLogFactory
|
||||
* @return LoggerInterface instance of logger object implementing LoggerInterface
|
||||
*/
|
||||
public function getLogger($className);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ use PayPal\Core\PayPalConfigManager;
|
||||
use Psr\Log\AbstractLogger;
|
||||
use Psr\Log\LogLevel;
|
||||
|
||||
|
||||
class PayPalLogger extends AbstractLogger
|
||||
{
|
||||
|
||||
@@ -75,11 +74,11 @@ class PayPalLogger extends AbstractLogger
|
||||
|
||||
public function log($level, $message, array $context = array())
|
||||
{
|
||||
if($this->isLoggingEnabled) {
|
||||
if ($this->isLoggingEnabled) {
|
||||
// Checks if the message is at level below configured logging level
|
||||
if (array_search($level, $this->loggingLevels) <= array_search($this->loggingLevel, $this->loggingLevels)) {
|
||||
error_log("[" . date('d-m-Y h:i:s') . "] " . $this->loggerName . " : " . strtoupper($level) . ": $message\n", 3, $this->loggerFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user