Skip to content

Commit

Permalink
Hook into railties correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
mak-dunkelziffer committed Aug 27, 2024
1 parent e2a24ab commit d3c57b1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/consul/active_record.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,6 @@ def authorize_values_for(property, options = {})
end
end

ActiveRecord::Base.send(:extend, Consul::ActiveRecord)
ActiveSupport.on_load(:active_record) do
extend(Consul::ActiveRecord)
end

0 comments on commit d3c57b1

Please sign in to comment.