fix js error that happens when enter is pressed and there is no highlighted option. fixes #1469