Fixed a minor bug where form was getting submitting as well