Skip to content

Commit e8243db

Browse files
committed
[fix] A @JsonProperty cannot be used for enums
I applied the same pattern than others enum
1 parent 11889b8 commit e8243db

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed
Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,21 @@
11
package org.zendesk.client.v2.model;
22

3-
import com.fasterxml.jackson.annotation.JsonProperty;
4-
53
/**
64
* https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/
75
*/
86
public enum CommentType {
97

10-
@JsonProperty("Comment") COMMENT,
11-
@JsonProperty("VoiceComment") VOICE_COMMENT;
8+
COMMENT("Comment"),
9+
VOICE_COMMENT("VoiceComment");
10+
11+
private final String name;
12+
13+
CommentType(String name) {
14+
this.name = name;
15+
}
1216

17+
@Override
18+
public String toString() {
19+
return name;
20+
}
1321
}

0 commit comments

Comments
 (0)