Skip to content
Snippets Groups Projects
Verified Commit 62974cc4 authored by Gwyneth Llewelyn's avatar Gwyneth Llewelyn :thinking:
Browse files

Fix: make sure that 'file'/'line' are not empty

There may be no guarantee that `$caller[...]` is actually set, or that
either `file` or `line` are not empty.
parent 39c76960
No related branches found
No related tags found
No related merge requests found
.DS_Store
.idea
/nbproject/private/
.phplint-cache
*.swp
# macOS-specific things to exclude
# General
.DS_Store
.AppleDouble
.LSOverride
# Icon must end with two \r
Icon
Icon?
# Thumbnails
._*
# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
# Configuration for the Nova editor
.nova
\ No newline at end of file
......@@ -251,7 +251,9 @@ class app {
$priority_txt = 'DEBUG';
$bt = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 1); // we don't need _all_ data, so we save some processing time here (gwyneth 20220315)
$caller = array_shift($bt);
$file_line_caller = '[' . strtr(basename($caller['file'], '.php'), '_', ' ') . ':' . $caller['line'] . '] ';
if(!empty($caller['file']) && !empty($caller['line'])) {
$file_line_caller = '[' . strtr(basename($caller['file'], '.php'), '_', ' ') . ':' . $caller['line'] . '] ';
}
break;
case 1:
$priority_txt = 'WARNING';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment