@@ -32,7 +32,7 @@ public EmailOnPushService withTagPushEvents(Boolean pushEvents) {
32
32
33
33
@ JsonIgnore
34
34
public String getRecipients () {
35
- return (( String ) getProperty (RECIPIENT_PROP ));
35
+ return (getProperty (RECIPIENT_PROP ));
36
36
}
37
37
public void setRecipients (String recipients ) {
38
38
setProperty (RECIPIENT_PROP , recipients );
@@ -45,7 +45,7 @@ public EmailOnPushService withRecipients(String recipients) {
45
45
46
46
@ JsonIgnore
47
47
public Boolean getDisableDiffs () {
48
- return Boolean .valueOf (getProperty (DISABLE_DIFFS_PROP ," false" ));
48
+ return Boolean .valueOf (getProperty (DISABLE_DIFFS_PROP , false ));
49
49
}
50
50
public void setDisableDiffs (Boolean disableDiffs ) {
51
51
setProperty (DISABLE_DIFFS_PROP , disableDiffs );
@@ -54,10 +54,10 @@ public EmailOnPushService withDisableDiffs(Boolean disableDiffs) {
54
54
setDisableDiffs (disableDiffs );
55
55
return this ;
56
56
}
57
-
57
+
58
58
@ JsonIgnore
59
59
public Boolean getSendFromCommitterEmail () {
60
- return Boolean .valueOf (getProperty (SEND_FROM_COMMITTER_EMAIL_PROP ," false" ));
60
+ return Boolean .valueOf (getProperty (SEND_FROM_COMMITTER_EMAIL_PROP , false ));
61
61
}
62
62
public void setSendFromCommitterEmail (Boolean sendFromCommitterEmail ) {
63
63
setProperty (SEND_FROM_COMMITTER_EMAIL_PROP , sendFromCommitterEmail );
@@ -68,16 +68,20 @@ public EmailOnPushService withSendFromCommitterEmail(Boolean sendFromCommitterEm
68
68
}
69
69
70
70
@ JsonIgnore
71
- public String getBranchesToBeNotified () {
72
- return ((String )getProperty (BRANCHES_TO_BE_NOTIFIED_PROP ));
71
+ public BranchesToBeNotified getBranchesToBeNotified () {
72
+ String branchesToBeNotified = getProperty (BRANCHES_TO_BE_NOTIFIED_PROP );
73
+
74
+ if (branchesToBeNotified == null || branchesToBeNotified .isEmpty ()) {
75
+ return null ;
76
+ }
77
+
78
+ return (BranchesToBeNotified .valueOf (branchesToBeNotified .toUpperCase ()));
73
79
}
74
- public void setBranchesToBeNotified (String branchesToBeNotified ) {
75
- setProperty (BRANCHES_TO_BE_NOTIFIED_PROP , branchesToBeNotified );
80
+ public void setBranchesToBeNotified (BranchesToBeNotified branchesToBeNotified ) {
81
+ setProperty (BRANCHES_TO_BE_NOTIFIED_PROP , branchesToBeNotified . toString () );
76
82
}
77
- public EmailOnPushService withBranchesToBeNotified (String branchesToBeNotified ) {
83
+ public EmailOnPushService withBranchesToBeNotified (BranchesToBeNotified branchesToBeNotified ) {
78
84
setBranchesToBeNotified (branchesToBeNotified );
79
85
return this ;
80
86
}
81
-
82
-
83
87
}
0 commit comments