Prevent or delete CR from user input

What is the best way to handle this?