2014/05/22分のコミットです。
CHANGELOGにのったコミットは以下の通りです(詳細は本文参照)。
- Fixed serialized fields returning serialized data after being updated with
update_column
. - When a
group
is set,sum
,size
,average
,minimum
andmaximum
on a NullRelation should return a Hash.
Add missing nodocs to MySQL adapter
activerecord/lib/active_record/connection_adapters/mysql_adapter.rb
の修正です。
:nodoc:
を追加しています。
Revert "Merge pull request #14544 from jefflai2/named_scope_sti"
昨日マージされたnamed scopeに関するバグ修正のPRをrevertしています。
このPRにより、activerecord-deprecated_finders
のgemが壊れてしまったとの事です。
Merge pull request #14613 from Sirupsen/fix-serialize-update-column
serialized fieldsを使用している時に、update_column
メソッドで値を更新した際に、serialize済みのデータを戻すよう修正しています。
Rename oid_type
to cast_type
to make PG columns consistent
activerecord/lib/active_record/connection_adapters/postgresql/column.rb
の修正です。
oid_type
をcast_type
に変数名を変更しています。
fixes in active record query for reorder
rails guideのActive Record Query Interface
の修正です。
発行されるSQLが間違えてたのを修正しています。
push the formatter up to the Route object
actionpack/lib/action_dispatch/journey/route.rb
の修正です。
Visitors::FormatBuilderをActionDispatch::Journey::Route
クラスで保持するよう修正しています。
do not mutate parameters, let the caller do mutations
ActionDispatch::Journey::Route#format
で行っていたパラメータのチェック処理を、ActionDispatch::Journey::Formattr##generate
メソッドで行うよう修正しています。
actionpack/lib/action_dispatch/journey/route.rb
の修正です。
変数名を、formatter
->path_formatter
に修正しています。
actionpack/lib/action_dispatch/routing/route_set.rb
の修正です。
オブジェクトの生成処理を減らすよう修正しています。
コミットログにオブジェクト生成を記録した際のサンプルソースが乗っています。ご参考に。
reuse path formatter from the non-optimized path.
actionpack/lib/action_dispatch/journey
の修正です。
OptimizedPath
クラスに関する処理を消しています。まだ作業中のコミットのような。
Move extract_scale to decimal type
extract_scale
をdecimal typeに移動しています。
処理をtype objectに集約している一環だと思うのですが、内容いまいちわかりませんでした…。
actionpack/lib/action_controller/metal/url_for.rb
の修正です。
reverse_merge
を使用している箇所を、merge
を使用するように修正しています。
reverse_merge
がActiveSupportの拡張だからですね。
2014-05-22 07:51:28 +0900
remove dead code. @klass isn't used anymore
actionpack/lib/action_dispatch/routing/route_set.rb
の修正です。
使用していない変数の削除。
use the existing constant rather than the hardcoded string
actionpack/lib/action_dispatch/http/parameters.rb
の修正です。
Stringがハードコーディングされているのを、定数を使うように修正しています。
コミットログがあらぶっているのが面白いです。
middle variable is never used, so rm
@router.recognize
を呼び出している箇所から、使用してない変数を削除しています。
fewer object allocations and method calls during route match
ActionDispatch::Journey::Router#find_routes
メソッドの修正です。
オブジェクト生成を減らすようリファクタリングしています。
drop hash allocations during match
ActionDispatch::Journey::Router#find_routes
メソッドの修正です。
Hash#merge
呼び出しを減らしています。
Merge pull request #15218 from sgrif/sg-move-oid-types
activerecord/lib/active_record/connection_adapters/postgresql/oid.rb
の修正です。
一ファイルにまとめられていたActiveRecord::ConnectionAdapters::PostgreSQL::OID
配下のクラスを、それぞれ別ファイルに切り出しています。
Rename Posts to Articles in Guides, continuation of 2d446e77 / #13774 [ci skip]
rails guide全般の修正です。サンプルのモデルをPost
からArticle
に修正しています。
HTTPの方のpost
と混乱してややこしいから、という理由のようです。
guides/CHANGELOG.md
の修正です。
順番を入れ替えています。
Merge pull request #14803 from kuldeepaggarwal/null_relation_sum_fix
activerecord/lib/active_record/null_relation.rb
の修正です。
NullRelation
でgroup
を設定している時に、, sum
, size
, average
, minimum
、maximum
がHash
を戻すよう修正しています。
Form full URI as string to be parsed in Rack::Test.
actionpack/lib/action_dispatch/testing/integration.rb
の修正です。
URIを生成するのに、元々はURI
クラスを使用していたのを、String
で文字連結するよう修正しています。
性能改善のためとの事。数字等はPR参照。
activerecord/test/cases/adapters/postgresql/datatype_test.rb
の修正です。
使用していないコードの削除。
Do not gsub non ASCII characters in header anchor.
guides/rails_guides/markdown.rb
の修正です。
ASCII以外の文字をアンカーに指定出来なかったのを、ASCII以外の文字も使用出来るよう修正しています。
pg test, extract network address type tests into separate file.
PostgreSQL DBAdapterのテストの修正です。
ネットワーク関係のテストを、activerecord/test/cases/adapters/postgresql/network_test.rb
にまとめています。
pg test, move timestamp tests over to postgresql/timestamp_test.rb
.
PostgreSQL DBAdapterのテストの修正です。
timestampのテストを、activerecord/test/cases/adapters/postgresql/timestamp_test.rb
にまとめています。
pg test, extract tsvector tests into postgresql/full_text_test.rb
PostgreSQL DBAdapterのテストの修正です。
full textのテストを、activerecord/test/cases/adapters/postgresql/full_text_test.rb
にまとめています。
Use break
instead of next
in AD::Journey::Formatter#match_route
ActionDispatch::Journey::Formatter#match_route
メソッドの修正です。
hash.keys.sort.reverse_each
した値でループを回しているので、一度0以下の値が出たら、以降全て0以下になるはずなので、next
ではなく、break
を使うよう修正しています。
Fix the hash key being delete from env
actionpack/lib/action_dispatch/http/parameters.rb
の修正です。
文字列がハードコードされている箇所を定数に置き換える修正で、誤った修正が行われてしまったので、文字列に戻しています。