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 841e7e2 commit d999d72Copy full SHA for d999d72
lib/optimizely/audience.rb
@@ -112,12 +112,12 @@ def get_segments(conditions)
112
# Returns array of segment names.
113
segments = []
114
115
- conditions.each do |condition|
116
- case condition
117
- when Array
+ case conditions
+ when Hash
+ segments.push(conditions['value']) if conditions.fetch('match', nil) == 'qualified'
118
+ when Array
119
+ conditions.each do |condition|
120
segments.concat @parse_segments.call(condition)
- when Hash
- segments.push(condition['value']) if condition.fetch('match', nil) == 'qualified'
121
end
122
123
0 commit comments