@@ -335,14 +335,18 @@ $in_sequences.get("$resource.getUriTemplate()").get($uri)
335
335
</then >
336
336
<else >
337
337
#if( $environmentType !='hybrid' )
338
+ #if( $resource.getAuthType() == 'None' && $environmentType == 'sandbox'
339
+ && $endpoint_config.get("sandbox_endpoints") )
340
+ #draw_endpoint( "sandbox" $endpoint_config )
341
+ #else
338
342
<payloadFactory >
339
343
<format >
340
344
<error xmlns =" " >
341
- #if( $environmentType == 'production' )
345
+ #if( $environmentType == 'production' )
342
346
<message >Sandbox Key Provided for Production Gateway</message >
343
- #elseif( $environmentType == 'sandbox' )
347
+ #elseif( $environmentType == 'sandbox' )
344
348
<message >Production Key Provided for Sandbox Gateway</message >
345
- #end
349
+ #end
346
350
</error >
347
351
</format >
348
352
</payloadFactory >
@@ -352,14 +356,19 @@ $in_sequences.get("$resource.getUriTemplate()").get($uri)
352
356
<property name =" HTTP_SC" value =" 401" scope =" axis2" />
353
357
<property name =" NO_ENTITY_BODY" scope =" axis2" action =" remove" />
354
358
<send />
359
+ #end
355
360
#else
356
361
#if( $endpoint_config.get("production_endpoints")
357
362
&& $endpoint_config.get("sandbox_endpoints") )
358
363
#draw_endpoint( "sandbox" $endpoint_config )
359
364
#elseif( $endpoint_config.get("production_endpoints") )
360
365
<sequence key =" _sandbox_key_error_" />
361
366
#elseif( $endpoint_config.get("sandbox_endpoints") )
367
+ #if( $resource.getAuthType() == 'None' )
368
+ #draw_endpoint( "sandbox" $endpoint_config )
369
+ #else
362
370
<sequence key =" _production_key_error_" />
371
+ #end
363
372
#end
364
373
#end
365
374
</else >
0 commit comments