mccalltd / AttributeRouting

Define your routes using attributes on actions in ASP.NET MVC and Web API.
http://mccalltd.github.io/AttributeRouting/
MIT License
416 stars 89 forks source link

Same route with different Http Verbs does not work #278

Closed juanespinosa closed 11 years ago

juanespinosa commented 11 years ago

Hi,

I have two routes with different verbs, but only works the first route in the code... Is this a bug? or Am I missing something?

Regards,

[GET("upload")]
public HttpResponseMessage Get()
{
return Request.CreateResponse(HttpStatusCode.OK);
}

[POST("upload")]
public HttpResponseMessage PostFiles()
{
return Request.CreateResponse(HttpStatusCode.OK);
}

I get this error

{"Message":"The requested resource does not support http method 'POST'."}

https://gist.github.com/juanespinosa/7536288

juanespinosa commented 11 years ago

Sorry, seems to be a misconfiguration in my app... everything is ok