 
     email = event.target.value.toLowerCase()
 
-    if not email
-      template.hasAccount.set true
+    if not Apollos.validate.isEmail email
+      template.hasErrors.set true
 
     Apollos.user.getAccountType email, (error, accountType) ->
       if error

    terms = template.find("input[name=terms]").checked

    if not Apollos.validate.isEmail email
      emailTemplate = template.email.get()
      emailTemplate.methods.setStatus true
      return

    if not Apollos.validate.isEmail email
      emailTemplate = template.email.get()
      emailTemplate.methods.setStatus true
      return

    if not password
      passwordTemplate = template.password.get()
      passwordTemplate.methods.setStatus "Password cannot be empty", true
      return

    if not terms
      termsTemplate = template.terms.get()
      termsTemplate.methods.setStatus "You must accept the terms and conditions", true
      return

        else
          template._.createAccount email, password

  # TODO fix link not working when using enter to submit form
  "click [data-forgot-password]": (event, template) ->

    if event.target.dataset?.forgotPassword
