Fixed url_for method for Rails > 4.1