Skip to content

Commit

Permalink
refactor: Skip phpError processing in CLI environment
Browse files Browse the repository at this point in the history
  • Loading branch information
yama committed Jul 11, 2024
1 parent 2deafc6 commit 735c1f0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions manager/includes/document.parser.class.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -5066,6 +5066,10 @@ function parsePlaceholder($src = '', $ph = [], $left = '[+', $right = '+]', $mod

function phpError($nr, $text, $file, $line)
{
// CLI環境であれば処理をスキップ
if (php_sapi_name() == 'cli') {
return true;
}
if (error_reporting() == 0 || $nr == 0) {
return true;
}
Expand Down

0 comments on commit 735c1f0

Please sign in to comment.