check if variable exists before accessing it, fixes #4480

Merge request reports

Loading