@@ -242,9 +242,11 @@ public virtual LogEvent CreateImpressionEvent(ProjectConfig config, Experiment e
242
242
GetImpressionOrConversionParamsWithCommonParams ( commonParams ,
243
243
new object [ ] { impressionOnlyParams } ) ;
244
244
245
- var region = ! string . IsNullOrEmpty ( config . Region ) ? config . Region : "US" ;
245
+ var endpoint = EventFactory . EventEndpoints . ContainsKey ( region )
246
+ ? EventFactory . EventEndpoints [ region ]
247
+ : EventFactory . EventEndpoints [ "US" ] ;
246
248
247
- return new LogEvent ( EventFactory . EventEndpoints [ region ] , impressionParams , HTTP_VERB , HTTP_HEADERS ) ;
249
+ return new LogEvent ( endpoint , impressionParams , HTTP_VERB , HTTP_HEADERS ) ;
248
250
}
249
251
250
252
@@ -270,9 +272,11 @@ public virtual LogEvent CreateConversionEvent(ProjectConfig config, string event
270
272
var conversionParams =
271
273
GetImpressionOrConversionParamsWithCommonParams ( commonParams , conversionOnlyParams ) ;
272
274
273
- var region = ! string . IsNullOrEmpty ( config . Region ) ? config . Region : "US" ;
275
+ var endpoint = EventFactory . EventEndpoints . ContainsKey ( region )
276
+ ? EventFactory . EventEndpoints [ region ]
277
+ : EventFactory . EventEndpoints [ "US" ] ;
274
278
275
- return new LogEvent ( EventFactory . EventEndpoints [ region ] , conversionParams , HTTP_VERB , HTTP_HEADERS ) ;
279
+ return new LogEvent ( endpoint , conversionParams , HTTP_VERB , HTTP_HEADERS ) ;
276
280
}
277
281
}
278
282
}
0 commit comments