added isset test for variable