画像アップローダーを作成し、その中に次のバージョンを定義しました
version :profile do
process :resize_and_pad [100, 100]
end
ファイルをアップロードすると、次のエラー メッセージが表示されます。
nil is not a symbol
完全なスタック トレースを見ると、それは processing.rb から来ています。
carrierwave (0.6.1) lib/carrierwave/uploader/processing.rb:85:in `block in process!'
carrierwave (0.6.1) lib/carrierwave/uploader/processing.rb:81:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/processing.rb:81:in `process!'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `block in with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/cache.rb:112:in `cache!'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:230:in `block in cache_versions!'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:216:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:216:in `cache_versions!'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `block in with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/cache.rb:112:in `cache!'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:230:in `block in cache_versions!'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:216:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/versions.rb:216:in `cache_versions!'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `block in with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `each'
carrierwave (0.6.1) lib/carrierwave/uploader/callbacks.rb:18:in `with_callbacks'
carrierwave (0.6.1) lib/carrierwave/uploader/cache.rb:112:in `cache!'
carrierwave (0.6.1) lib/carrierwave/mount.rb:315:in `cache'
carrierwave (0.6.1) lib/carrierwave/mount.rb:173:in `profile_image='
carrierwave (0.6.1) lib/carrierwave/orm/activerecord.rb:37:in `profile_image='
activerecord (3.2.2) lib/active_record/attribute_assignment.rb:85:in `block in assign_attributes'
activerecord (3.2.2) lib/active_record/attribute_assignment.rb:78:in `each'
activerecord (3.2.2) lib/active_record/attribute_assignment.rb:78:in `assign_attributes'
activerecord (3.2.2) lib/active_record/persistence.rb:212:in `block in update_attributes'
activerecord (3.2.2) lib/active_record/transactions.rb:295:in `block in with_transaction_returning_status'
activerecord (3.2.2) lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'
activerecord (3.2.2) lib/active_record/transactions.rb:208:in `transaction'
activerecord (3.2.2) lib/active_record/transactions.rb:293:in `with_transaction_returning_status'
activerecord (3.2.2) lib/active_record/persistence.rb:211:in `update_attributes'
app/controllers/users_controller.rb:24:in `update_profile'