Skip to content

Commit

Permalink
Check for MassAssignmentSecurity when determining whether to call att…
Browse files Browse the repository at this point in the history
…r_accessible

AR 4 may require attr_accessible if the protected_attributes gem is installed
  • Loading branch information
tombenner committed Mar 26, 2014
1 parent 7a0d5d1 commit d92a14d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/sidekiq/superworker/subjob.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module Superworker
class Subjob < ActiveRecord::Base
attr_accessible :jid, :subjob_id, :superjob_id, :parent_id, :children_ids, :next_id,
:subworker_class, :superworker_class, :arg_keys, :arg_values, :status, :descendants_are_complete,
:meta if ActiveRecord::VERSION::MAJOR < 4
:meta if ActiveRecord::VERSION::MAJOR < 4 || ActiveRecord.constants.include?(:MassAssignmentSecurity)

serialize :arg_keys
serialize :arg_values
Expand Down

0 comments on commit d92a14d

Please sign in to comment.