changed isset to isempty