diff options
Diffstat (limited to 'guides/source/4_2_release_notes.md')
-rw-r--r-- | guides/source/4_2_release_notes.md | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/guides/source/4_2_release_notes.md b/guides/source/4_2_release_notes.md index c59affea8f..d9f49aac55 100644 --- a/guides/source/4_2_release_notes.md +++ b/guides/source/4_2_release_notes.md @@ -79,7 +79,7 @@ post.comments(true) # uses cached pattern The caching is not used in the following scenarios: - The model has a default scope -- The model uses single table inheritence to inherit from another model +- The model uses single table inheritance to inherit from another model - `find` with a list of ids. eg: ```ruby @@ -149,6 +149,13 @@ individual components for new deprecations in this release. The following changes may require immediate action upon upgrade. +### `render` with a String argument + +Previously, calling `render "foo/bar"` in a controller action is equivalent to +`render file: "foo/bar"`. In Rails 4.2, this has been changed to mean `render template: "foo/bar"` +instead. If you need to render a file, please change your code to use the +explicit form (`render file: "foo/bar"`) instead. + ### `respond_with` / class-level `respond_to` `respond_with` and the corresponding class-level `respond_to` have been moved to @@ -388,6 +395,9 @@ Please refer to the [Changelog][action-pack] for detailed changes. ### Deprecations +* Deprecated the `only_path` option on `*_path` helpers. + ([Commit](https://github.com/rails/rails/commit/aa1fadd48fb40dd9396a383696134a259aa59db9)) + * Deprecated `assert_tag`, `assert_no_tag`, `find_tag` and `find_all_tag` in favor of `assert_select`. ([Commit](https://github.com/rails/rails-dom-testing/commit/b12850bc5ff23ba4b599bf2770874dd4f11bf750)) @@ -499,6 +509,10 @@ Please refer to the [Changelog][action-view] for detailed changes. ### Notable changes +* `render "foo/bar"` now expands to `render template: "foo/bar"` instead of + `render file: "foo/bar"`. + ([Pull Request](https://github.com/rails/rails/pull/16888)) + * Introduced a `#{partial_name}_iteration` special local variable for use with partials that are rendered with a collection. It provides access to the current state of the iteration via the `#index`, `#size`, `#first?` and @@ -697,7 +711,7 @@ Please refer to the [Changelog][active-model] for detailed changes. (Pull Request [1](https://github.com/rails/rails/pull/14861), [2](https://github.com/rails/rails/pull/16180)) -* `has_secure_password` no longer disallow blank passwords (i.e. passwords +* `has_secure_password` no longer disallows blank passwords (i.e. passwords that contains only spaces) by default. ([Pull Request](https://github.com/rails/rails/pull/16412)) @@ -739,10 +753,14 @@ Please refer to the [Changelog][active-support] for detailed changes. ### Notable changes +* `Object#try` and `Object#try!` can now be used without an explicit receiver. + ([Commit](https://github.com/rails/rails/commit/5e51bdda59c9ba8e5faf86294e3e431bd45f1830), + [Pull Request](https://github.com/rails/rails/pull/17361)) + * Introduced new configuration option `active_support.test_order` for specifying the order test cases are executed. This option currently defaults to `:sorted` but will be changed to `:random` in Rails 5.0. - ([Commit](TODO: fill me in)) + ([Commit](https://github.com/rails/rails/commit/53e877f7d9291b2bf0b8c425f9e32ef35829f35b)) * The `travel_to` test helper now truncates the `usec` component to 0. ([Commit](https://github.com/rails/rails/commit/9f6e82ee4783e491c20f5244a613fdeb4024beb5)) |