SCALARIZR-1678 correctly perform file existance check