title: type mismatch; found : play.api.data.Form[controllers.Application.Userdata] required: play.api.data.Form[(String, String)]
body: <p>i have created a simply login submit form using playframework and scala without connecting any database.</p>
  
  <p><strong>my <code>application.scala</code> which is my controller i have written the code</strong> </p>
  
  <pre><code>import play.api._
  import play.api.mvc._
  import play.api.data._
  import play.api.data.Forms._
  import play.api.mvc.Request
  import views.html._
  
  case class Userdata(email:String,password:String)
  
  object Application extends Controller {
  
    case class Userdata(email:String,password:String)
  
    val userForm = Form(
    mapping(
      "email" -&gt; text,
      "password" -&gt; text
    )(Userdata.apply)(Userdata.unapply)
  )
  
     def usercheck = Action{ implicit request=&gt;
  
      userForm.bindFromRequest.fold(
        formWithErrors =&gt; BadRequest(views.html.login(formWithErrors)),
           Userdata =&gt; {  Ok(views.html.index("congrates"))}
  
      )}
      def index() = Action {
      implicit request=&gt;
      Ok(views.html.login(userForm))
    }
  </code></pre>
  
  <p>and my view template is <code>login.scala.html</code>..</p>
  
  <pre><code>@(form: Form[(String,String)])
  
  @import helper._
  
  
      @form(routes.Application.usercheck){
      &lt;form class=frmuuser&gt;
        &lt;input type=text placeholder=email id='emailid'&gt;
        &lt;input type=password placeholder=password id='pwd'&gt;
        &lt;input type=submit value=login id='enter'&gt;
  
      &lt;/form&gt;
      }
  </code></pre>
  
  <p>but it is not working and giving me error</p>
  
  <pre><code>type mismatch; found : play.api.data.Form[controllers.Application.Userdata] required: play.api.data.Form[(String, String)]
  </code></pre>
  
  <p>in this line of contoller</p>
  
  <pre><code> formWithErrors =&gt; BadRequest(views.html.login(formWithErrors)), 
  </code></pre>
  
  <p>what is soultion for my problem??</p>