rails/rails — pull request #9439 by senny (2013-02-26 13:41:01+00:00)
Title: convert non-string default params to strings in the router.

Closes #9435.

Since Rails 4.0.0.beta1 Rails raises an exception when non-string default params
are provided in the router (eg. `root to: 'main#posts', page: 1`).

I see sevaral options to fix this:

1. issue a deprecation warning when non-string defaults are used.
2. convert all default params to strings.
3. get the router to work with non-string params (implemented by this patch).

I chose 3. becuase it's the only option, which is backwards compatible.
With 3.2.x the router happily accepted non-string default params.