Skip to content

Commit 1ead293

Browse files
authored
Fix: Added JsonInclude as always when serializing on campaign and experiment id. (#422)
1 parent 0eaf61b commit 1ead293

File tree

1 file changed

+4
-1
lines changed
  • core-api/src/main/java/com/optimizely/ab/event/internal/payload

1 file changed

+4
-1
lines changed

core-api/src/main/java/com/optimizely/ab/event/internal/payload/Decision.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
*
3-
* Copyright 2018-2020, Optimizely and contributors
3+
* Copyright 2018-2021, Optimizely and contributors
44
*
55
* Licensed under the Apache License, Version 2.0 (the "License");
66
* you may not use this file except in compliance with the License.
@@ -16,12 +16,15 @@
1616
*/
1717
package com.optimizely.ab.event.internal.payload;
1818

19+
import com.fasterxml.jackson.annotation.JsonInclude;
1920
import com.fasterxml.jackson.annotation.JsonProperty;
2021
import com.optimizely.ab.annotations.VisibleForTesting;
2122

2223
public class Decision {
24+
@JsonInclude(JsonInclude.Include.ALWAYS)
2325
@JsonProperty("campaign_id")
2426
String campaignId;
27+
@JsonInclude(JsonInclude.Include.ALWAYS)
2528
@JsonProperty("experiment_id")
2629
String experimentId;
2730
@JsonProperty("variation_id")

0 commit comments

Comments
 (0)