Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordiosmosis <benaka@piwik.pro>2015-09-22 03:01:55 +0300
committerdiosmosis <benaka@piwik.pro>2015-09-22 03:01:55 +0300
commit86f20f6cc05bfceb2fed94764228f70510b2741b (patch)
treefa3bc8feb1f9dc8d46736e6fcb90dce6d3ec76e1 /plugins/Monolog
parentd18300888a13faefd76e66b3c138efef55b79b34 (diff)
Attempt to fix build.
Diffstat (limited to 'plugins/Monolog')
-rw-r--r--plugins/Monolog/Formatter/LineMessageFormatter.php2
-rw-r--r--plugins/Monolog/tests/Integration/LogTest.php2
2 files changed, 3 insertions, 1 deletions
diff --git a/plugins/Monolog/Formatter/LineMessageFormatter.php b/plugins/Monolog/Formatter/LineMessageFormatter.php
index 8224ff71f6..c9bff1e77b 100644
--- a/plugins/Monolog/Formatter/LineMessageFormatter.php
+++ b/plugins/Monolog/Formatter/LineMessageFormatter.php
@@ -40,7 +40,7 @@ class LineMessageFormatter implements FormatterInterface
$class = isset($record['extra']['class']) ? $record['extra']['class'] : '';
$date = $record['datetime']->format('Y-m-d H:i:s');
- $message = $record['message'];
+ $message = trim($record['message']);
if ($this->allowInlineLineBreaks) {
$message = str_replace("\n", "\n ", $message); // intend lines
diff --git a/plugins/Monolog/tests/Integration/LogTest.php b/plugins/Monolog/tests/Integration/LogTest.php
index 97dc5e818f..75a8166d4f 100644
--- a/plugins/Monolog/tests/Integration/LogTest.php
+++ b/plugins/Monolog/tests/Integration/LogTest.php
@@ -201,6 +201,8 @@ class LogTest extends IntegrationTestCase
$fileContents = file_get_contents(self::getLogFileLocation());
$fileContents = $this->removePathsFromBacktrace($fileContents);
+ $expectedMessage = str_replace("\n ", "\n[Monolog]", $expectedMessage);
+
$this->assertEquals($expectedMessage . "\n", $fileContents);
} else if ($backend == 'database') {
$queryLog = Db::isQueryLogEnabled();