fixed form submit reset input logic