Zack,
The pluralization is intentional. This is because of the collection-
oriented nature of resources. If you have a "message" resource, you
get the collection of all messages at "/messages", and a single
message at "/messages/2". The controller itself manages
"messages" (serves up either the collection, or any number of
messages one at a time).
- Jamis
On Jun 28, 2006, at 11:18 AM, Zack Chandler wrote:
I love the simply_restful plugin (beautiful work Jamis) but wonder why
the naming convention changed to look for pluralized controllers by
default.
If you do:
map.resource :message
then you must have a MessagesController.
If you already have a MessageController you need:
map.resource :message, :controller => 'message'
which is slightly less DRY.
Is this a change in convention to pluralize controller names? Almost
all the examples in the docs and rails books use singular controller
names. I'd be happy to make a patch if this is an unwanted
side-effect of the plugin.
Thanks,
Zack Chandler
_______________________________________________
Rails-core mailing list
Rails-core@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-core
_______________________________________________
Rails-core mailing list
Rails-core@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-core