lib/voltron/encrypt/engine.rb in voltron-encrypt-0.1.3 vs lib/voltron/encrypt/engine.rb in voltron-encrypt-0.1.4

- old
+ new

@@ -4,9 +4,10 @@ isolate_namespace Voltron initializer "voltron.encrypt.initialize" do ::ActiveRecord::Base.send :extend, ::Voltron::Encryptable + ::ActiveRecord::Associations::CollectionAssociation.send :prepend, ::Voltron::Encrypt::ActiveRecord::CollectionAssociation # Corrects sidekiq resource lookup by forcing it to find_by_id rather than find with the model id # We either want it to find with to_param value, or find_by_id with the actual id, this is the latter ::GlobalID::Locator.use Rails.application.railtie_name.remove("_application").dasherize do |gid| gid.model_class.find_by_id gid.model_id