mirror of
https://github.com/Icinga/icinga2.git
synced 2025-04-08 17:05:25 +02:00
WarnOnImplicitlySetGlobalVar(): warn only on sins inside actual DSL code
This commit is contained in:
parent
3a154516dc
commit
b4e3736e31
@ -560,7 +560,7 @@ void WarnOnImplicitlySetGlobalVar(const std::unique_ptr<Expression>& setLhs, con
|
||||
if (var && setLhsParent.IsObject()) {
|
||||
auto ns (dynamic_pointer_cast<Namespace>(setLhsParent.Get<Object::Ptr>()));
|
||||
|
||||
if (ns && ns == ScriptGlobal::GetGlobals()) {
|
||||
if (ns && ns == ScriptGlobal::GetGlobals() && debug.Path.GetLength()) {
|
||||
const char *opStr = nullptr;
|
||||
|
||||
switch (setOp) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user