update email verify flow and error handling