fixed bug on submitting application