Pressing Escape while editing - revocable using undo?

Coming from OF 1 I apparently am used to using the Escape key to end processing when I edit. I am aware that it is possible to choose between Classic Mode and Modern Mode. I’ve decided to use Modern Mode because I like the way it works in general. However, due to old ingrained finger habits I sometimes hit the Escape key to terminate my editing. That seems to delete everything in the line I was just working on. Irrevocably! :-(

It would be a huge help for me if it were possible to undo the unintended results of hitting the Escape key. Would it be possible to add that functionality?