2014/09/04分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
schema loading rake tasks maintain database connection for current env.
activerecord/lib/active_record/tasks/database_tasks.rb
の修正です。
スキーマをロードするタスク(db:schema:load
やdb:setup
など)で、現在の環境のDBコネクションを維持するよう修正しています。
copy edit AS core ext changes [ci skip]
rails guideのActive Support Core Extensions
の修正です。
グラマーの修正です。
Ship with rails-html-sanitizer instead.
ActionPack/ActionViewの修正です。
rails-deprecated_sanitizer
の代わりにrails-html-sanitizer
を使用するよう修正しています。
extract updating all fixture cache to a method so we can lock later
activerecord/lib/active_record/fixtures.rb
の修正です。
create_fixtures
メソッドで行っているfixtureの更新処理を、update_all_loaded_fixtures
メソッドに切り出しています。
activesupport/lib/active_support/core_ext/object/duplicable.rb
の修正です。
Method
オブジェクトについては、duplicate出来ないよう対応しています。
method(:puts).duplicable? # => false method(:puts).dup # => TypeError: allocator undefined for Method
確かに、普通に考えるとメソッドについては複製出来なくて良い気がしますねえ。
Add support for ARIA attributes in tags
actionview/lib/action_view/helpers/tag_helper.rb
の修正です。
tag出力処理、ARIA属性のサポートを追加しています。
<%= f.text_field :name, aria: { required: "true", hidden: "false" } %> # => <input aria-hidden="false" aria-required="true" id="user_name" name="user[name]" type="text">
ARIA、正確には"WAI-ARIA"とは、Web Accessibility Initiative-Accessible Rich Internet Applicationsの略で、リッチなインターネットアプリケーションのアクセシビリティに関する仕様書との事だそうです。知らなかった。詳細は、W3C参照。
Extract data/aria attribute prefixes to a constant
actionview/lib/action_view/helpers/tag_helper.rb
の修正です。
コード内にべたに定義されていたprefixを定数に切り出しています。
code gardening in ActionController::Renderers
actionpack/lib/action_controller/metal/renderers.rb
の修正です。
諸々リファクタリングを行っています。
_handle_render_options
を_render_to_body_with_renderer
にリネーム- メソッド名生成の為の
_render_with_renderer_method_name
の作成 - 不要な
self
の削除
[ci skip] Fix typo in rails guide for routing
rails guideのRails Routing from the Outside In
の修正です。
タイポの修正です。
get rid of shadowing warning when running tests AR and railtie tests.
activerecord/lib/active_record/associations/association_scope.rb
の修正です。
add_constraints
メソッドで、同名の変数がありwarningが出力されていたので、変数名を修正しています。
build fix, we have to reset the RACK_ENV as well.
railties/test/application/rake/dbs_test.rb
の修正です。
テストの前処理で元々のRAILS_ENV
、RACK_ENV
の値を保持してい、後処理で元の値に戻すよう修正しています。
Enums shouldn't ruin people's anniversaries
activerecord/lib/active_record/attribute_methods.rb
の修正です。
BLACKLISTED_CLASS_METHODS
にallocate
、new
、 name
、 parent
、superclass
を追加しています。
元々はprivate
、public
、protected
だけだったのですが、enumのkeyにparent
等の値を指定されると、エラーになってしまので、重要なメソッドを追加しています。
activerecord/lib/active_record/associations/association_scope.rb
の修正です。
"#16762"で行った変数名の修正について、もう少し適切な名前に変数名を修正しています。
activejob/lib/active_job/arguments.rb
の修正です。
メソッドと引数の間に不要なスペースがある、ワーニングが出てしまっていたので、スペースの削除を行っています。