We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ffc15d2 commit 9dc2db5Copy full SHA for 9dc2db5
lib/meilisearch/utils.rb
@@ -23,8 +23,12 @@ def self.parse(body)
23
end
24
25
26
+ def self.filter(original_options, allowed_params = [])
27
+ original_options.transform_keys(&:to_sym).slice(*allowed_params)
28
+ end
29
+
30
def self.parse_query(original_options, allowed_params = [])
- only_allowed_params = original_options.transform_keys(&:to_sym).slice(*allowed_params)
31
+ only_allowed_params = filter(original_options, allowed_params)
32
33
Utils.transform_attributes(only_allowed_params).then do |body|
34
body.transform_values do |v|
0 commit comments