optimizely-sdk 4.0.1 → 5.0.0.pre.beta
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/optimizely/audience.rb +5 -5
- data/lib/optimizely/config/datafile_project_config.rb +542 -539
- data/lib/optimizely/config_manager/http_project_config_manager.rb +12 -4
- data/lib/optimizely/config_manager/project_config_manager.rb +2 -1
- data/lib/optimizely/config_manager/static_project_config_manager.rb +3 -2
- data/lib/optimizely/event_dispatcher.rb +2 -4
- data/lib/optimizely/exceptions.rb +15 -1
- data/lib/optimizely/helpers/constants.rb +45 -1
- data/lib/optimizely/helpers/http_utils.rb +3 -0
- data/lib/optimizely/helpers/sdk_settings.rb +61 -0
- data/lib/optimizely/helpers/validator.rb +55 -0
- data/lib/optimizely/notification_center_registry.rb +71 -0
- data/lib/optimizely/odp/lru_cache.rb +114 -0
- data/lib/optimizely/odp/odp_config.rb +102 -0
- data/lib/optimizely/odp/odp_event.rb +75 -0
- data/lib/optimizely/odp/odp_event_api_manager.rb +70 -0
- data/lib/optimizely/odp/odp_event_manager.rb +286 -0
- data/lib/optimizely/odp/odp_manager.rb +159 -0
- data/lib/optimizely/odp/odp_segment_api_manager.rb +122 -0
- data/lib/optimizely/odp/odp_segment_manager.rb +97 -0
- data/lib/optimizely/optimizely_config.rb +1 -1
- data/lib/optimizely/optimizely_factory.rb +7 -2
- data/lib/optimizely/optimizely_user_context.rb +40 -6
- data/lib/optimizely/user_condition_evaluator.rb +1 -1
- data/lib/optimizely/version.rb +2 -2
- data/lib/optimizely.rb +142 -10
- metadata +14 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0b1f844a1fb9c83e93efd101ccdb43ce162d11283b45c47e5d2f73a80a663bb4
|
4
|
+
data.tar.gz: d2b2e1fb6f1f38b523042503dbb547691f8023db8255f192cd0711c8f8498dc7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 54b774c53b729b87d8e3e889713bb9cf54954a9b95089806406eccf2f3bfbc85e7c1a75380964ecc5de6a946cdcf96f918d8be38807133dfe0b85c1d9d45380c
|
7
|
+
data.tar.gz: 756c2a224ad8a4b7946c950599d29ea824ad0c1789ce254e76b86eeac4d502901dc5d5510f25e26207a66c34bad7eea732a950db79199d90ec1dfac4c56c07ab
|
data/lib/optimizely/audience.rb
CHANGED
@@ -112,12 +112,12 @@ module Optimizely
|
|
112
112
|
# Returns array of segment names.
|
113
113
|
segments = []
|
114
114
|
|
115
|
-
conditions
|
116
|
-
|
117
|
-
|
115
|
+
case conditions
|
116
|
+
when Hash
|
117
|
+
segments.push(conditions['value']) if conditions.fetch('match', nil) == 'qualified'
|
118
|
+
when Array
|
119
|
+
conditions.each do |condition|
|
118
120
|
segments.concat @parse_segments.call(condition)
|
119
|
-
when Hash
|
120
|
-
segments.push(condition['value']) if condition.fetch('match', nil) == 'qualified'
|
121
121
|
end
|
122
122
|
end
|
123
123
|
|