bug fix: ie8 thinks undefined is and object >_< so add check for nullOrUndefined()