Clean up the Submit JS functionality.