Added form validation on the new device page