Open DiogenesAnalytics opened 7 months ago
The JS code responsible for "validating" form inputs is being duplicated in the event listeners for the "Send" and "Download Form" button respectively.
Refactor into a single function (e.g. validateForm()).
validateForm()
Problem
The JS code responsible for "validating" form inputs is being duplicated in the event listeners for the "Send" and "Download Form" button respectively.
Code:
Solution
Refactor into a single function (e.g.
validateForm()
).