Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rails 7.1 deep merge fix #9

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/resource_registry.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
require 'resource_registry/feature_dsl'
require 'resource_registry/configuration'
require 'resource_registry/registry'
require 'deep_merge/rails_compat'

module ResourceRegistry
end
2 changes: 1 addition & 1 deletion lib/resource_registry/registry.rb
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ def nested_namespaces
return @nested_namespaces if defined? @nested_namespaces

@nested_namespaces = namespace_features_hash.reduce({}) do |data, (namespace, features)|
data.deep_merge(namespace_to_hash(namespace.split('.'), features))
data.deeper_merge(namespace_to_hash(namespace.split('.'), features))
end
end

Expand Down
5 changes: 3 additions & 2 deletions taxonomies/hash_store.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# frozen_string_literal: true

require 'deep_merge'
require 'deep_merge/rails_compat'

module ResourceRegistry
module Stores
module Operations
Expand All @@ -10,7 +11,7 @@ class HashStore

def call(input)
if defined? ResourceRegistry::AppSettings
DeepMerge.deep_merge!(
DeepMerge.deeper_merge!(
input.to_h,
ResourceRegistry::AppSettings,
merge_hash_arrays: true,
Expand Down
Loading