Skip to content

Commit dda0fec

Browse files
author
Max Klyga
committed
Ignore enrichment properties during serialisation. Add getters for reaction enrichment data on activity
1 parent 45de65e commit dda0fec

File tree

3 files changed

+21
-6
lines changed

3 files changed

+21
-6
lines changed

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ plugins {
99
}
1010

1111
group 'io.getstream.client'
12-
version = '3.0.0'
12+
version = '3.0.1'
1313

1414
dependencies {
1515
testCompile 'org.junit.jupiter:junit-jupiter-api:5.3.1'

src/main/java/io/getstream/core/models/EnrichedActivity.java

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,21 @@ public Double getScore() {
9494
return score;
9595
}
9696

97+
@JsonIgnore
98+
public Map<String, Number> getReactionCounts() {
99+
return reactionCounts;
100+
}
101+
102+
@JsonIgnore
103+
public Map<String, List<Reaction>> getOwnReactions() {
104+
return ownReactions;
105+
}
106+
107+
@JsonIgnore
108+
public Map<String, List<Reaction>> getLatestReactions() {
109+
return latestReactions;
110+
}
111+
97112
@JsonAnyGetter
98113
public Map<String, Object> getExtra() {
99114
return extra;

src/main/java/io/getstream/core/models/Reaction.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,27 +66,27 @@ public String getParent() {
6666
return parent;
6767
}
6868

69-
@JsonProperty("own_children")
69+
@JsonIgnore
7070
public Map<String, List<Reaction>> getOwnChildren() {
7171
return ownChildren;
7272
}
7373

74-
@JsonProperty("latest_children")
74+
@JsonIgnore
7575
public Map<String, List<Reaction>> getLatestChildren() {
7676
return latestChildren;
7777
}
7878

79-
@JsonProperty("children_counts")
79+
@JsonIgnore
8080
public Map<String, Number> getChildrenCounts() {
8181
return childrenCounts;
8282
}
8383

84-
@JsonProperty("user")
84+
@JsonIgnore
8585
public Data getUserData() {
8686
return userData;
8787
}
8888

89-
@JsonProperty("data")
89+
@JsonIgnore
9090
public Map<String, Object> getActivityData() {
9191
return activityData;
9292
}

0 commit comments

Comments
 (0)