なるようになるブログ

読書感想文かrailsについてかrubyについてか

rails commit log流し読み(2019/02/28)

2019/02/28分のコミットです。

CHANGELOGへの追加はありませんでした。


Allow returning nil for default_scope

activerecord/lib/active_record/scoping/default.rbの修正です。

default_scopenilを返せるよう修正しています。


Refactor generated_relation_methods to remove duplicated code on ClassSpecificRelation

activerecord/lib/active_record/relation/delegation.rbの修正です。

ClassSpecificRelation module内の重複コードを消せるようgenerated_relation_methodsメソッドをリファクタリングしています。


add note about idle connection reaper to 5.2 release notes

rails guideのRuby on Rails 5.2 Release Notesの修正です。

idle状態のコネクションの扱いが変更になった対応(Flush idle database connections)についてrelease noteにエントリーを追加しています。


Use dedicated Topic model for SerializedAttributeTest

activerecord/test/cases/serialized_attribute_test.rbの修正です。

serialize attributeのテストで他のテストと同じmodelを使用していたのを、専用のmodelを使用するよう修正しています。テスト内でattributeを変更しており、それが他のテストに影響しないようにする為。


[ci skip] Fix the documentation of ActiveRecord::FinderMethods#find

activerecord/lib/active_record/relation/finder_methods.rbのdocの修正です。

ActiveRecord::FinderMethods#findメソッド内のRecordNotFoundActiveRecord::RecordNotFoundに修正、及び、to_iメソッドが呼ばれる場合の説明に誤りがあったのを修正しています。が、説明については元の内容が正しかった為、後ほど再修正されています。