replace !$undefined with !isset($undefined) #2655

#2655