mirror of
https://git.mills.io/prologic/zs
synced 2024-11-24 22:36:10 +03:00
Fix debugability of non-existent plugins or variables in non-production mode
This commit is contained in:
parent
3823e20a03
commit
97f798b5c5
1
.vscode/settings.json
vendored
1
.vscode/settings.json
vendored
@ -19,6 +19,7 @@
|
|||||||
"stefanfritsch",
|
"stefanfritsch",
|
||||||
"Strikethrough",
|
"Strikethrough",
|
||||||
"tasklist",
|
"tasklist",
|
||||||
|
"Texter",
|
||||||
"wikilink",
|
"wikilink",
|
||||||
"yuin",
|
"yuin",
|
||||||
"ZSCONFIG",
|
"ZSCONFIG",
|
||||||
|
4
main.go
4
main.go
@ -455,6 +455,10 @@ func render(s string, vars Vars) (string, error) {
|
|||||||
} else {
|
} else {
|
||||||
log.WithError(err).Warnf("error running command: %s", m[0])
|
log.WithError(err).Warnf("error running command: %s", m[0])
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if !viper.GetBool("production") {
|
||||||
|
out.WriteString(fmt.Sprintf("%s: plugin or variable not found", m[0]))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user