gives register form errors