fix: Handle possible null/empty case causing test to fail.
This commit is contained in:
parent
b4a86b597d
commit
d86b5dced3
|
@ -282,7 +282,8 @@ export def custom [
|
|||
$level_prefix
|
||||
}
|
||||
|
||||
let ansi = if not $env.config.use_ansi_coloring {
|
||||
let use_color = ($env | get config? | get use_ansi_coloring? | $in != false)
|
||||
let ansi = if not $use_color {
|
||||
""
|
||||
} else if ($ansi | is-empty) {
|
||||
if ($log_level not-in $valid_levels_for_defaulting) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user