Fix 'this.date is undefined' on keyUp/keyDown and empty input