Fix apply with enter key in modals.