replace file system check with WF check

`isset( $iVarId )` is probably sufficient here.