Skip to content

Commit 72bd47e

Browse files
committed
Switched to using Environment instead of using deprecated constant
1 parent fbdcb6c commit 72bd47e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Classes/Log/Writer/EchoWriter.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use Symfony\Component\Console\Output\OutputInterface;
66
use Symfony\Component\Console\Output\StreamOutput;
7+
use TYPO3\CMS\Core\Core\Environment;
78
use TYPO3\CMS\Core\Log\LogLevel;
89
use TYPO3\CMS\Core\Log\LogRecord;
910
use TYPO3\CMS\Core\Log\Writer\AbstractWriter;
@@ -20,7 +21,7 @@ class EchoWriter extends AbstractWriter {
2021
public function __construct(array $options = []) {
2122
parent::__construct($options);
2223

23-
if (!defined('TYPO3_REQUESTTYPE') || !(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_CLI)) {
24+
if (!Environment::isCli()) {
2425
// only output messages in CLI context
2526
return;
2627
}

0 commit comments

Comments
 (0)