2018/05/17分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
activestorage/CHANGELOG.md
Active Storageの修正です。
ActiveStorage::Blob#open
メソッドを追加しています。
open
メソッドはblobをディスクに一時ファイルとして保存し、そのファイルに対して処理を実行出来るようになっています。
例。
message.video.open do |file| system '/path/to/virus/scanner', file.path # ... end
合わせて、元々上記のような用途で使う想定だったActiveStorage::Downloading
moduleをdeprecateにしています。
Demonstrate ActiveStorage::Blob#open in the Active Storage guide
rails guideのActive Storage Overview
の修正です。
guideにActiveStorage::Blob#open
を使った場合のexampleを追加しています。
activestorage/lib/active_storage/analyzer.rb
、
activestorage/lib/active_storage/previewer.rb
の修正です。
メソッドの引数指定に誤りがあった箇所があったのを修正しています。
Add ActiveStorage::Previewer#tempdir
activestorage/lib/active_storage/previewer.rb
の修正です。
ActiveStorage::Previewer
にtempdir
メソッドを追加しています。元々はActiveStorage::Downloading
のtempdir
メソッドを使うようになっていたのですが、ActiveStorage::Downloading
がdeprecateになったため、独自にメソッドを定義するようにしています。
Remove unused require "active_support/core_ext/string/filters"
activestorage/lib/active_storage/previewer.rb
の修正です。
使用していないactive_support/core_ext/string/filters
のrequireを削除しています。
Active storage: Image variant options not correct
activestorage/app/models/active_storage/variant.rb
のdocの修正です。
ctiveStorage::Variant
classのdoc内、画像変換に指定するオプションに誤りがあったのを修正しています。
Fix formatting of author credit [ci skip]
activestorage/CHANGELOG.md
の修正です。
ActiveStorage::Blob#open
メソッドを追加した対応のエントリーの、author部分のフォーマットを修正しています。