Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

Commit ba08dd2

Browse files
thiyagu06skyhit
authored andcommitted
Fix for issue#389 (#75)
1 parent 494e69a commit ba08dd2

File tree

3 files changed

+32
-4
lines changed

3 files changed

+32
-4
lines changed

src/main/java/com/appirio/service/challengefeeder/api/DataScienceData.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
import java.util.Date;
1111
import java.util.List;
1212

13+
import org.apache.commons.lang3.StringUtils;
14+
1315
import lombok.Getter;
1416
import lombok.Setter;
1517

@@ -42,7 +44,6 @@ public abstract class DataScienceData {
4244
* The status field.
4345
*/
4446
@Getter
45-
@Setter
4647
private String status;
4748

4849
/**
@@ -158,4 +159,11 @@ public abstract class DataScienceData {
158159
@Getter
159160
@Setter
160161
private Long numberOfRegistrants;
162+
163+
/**
164+
* @param status the status to set
165+
*/
166+
public void setStatus(String status) {
167+
this.status = StringUtils.trim(status);
168+
}
161169
}

src/main/java/com/appirio/service/challengefeeder/api/PhaseData.java

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,13 @@
55

66
import java.util.Date;
77

8+
import org.apache.commons.lang3.StringUtils;
9+
810
import com.appirio.service.challengefeeder.helper.CustomDateDeserializer;
911
import com.fasterxml.jackson.annotation.JsonFormat;
1012
import com.fasterxml.jackson.annotation.JsonIgnore;
1113
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
14+
1215
import lombok.Getter;
1316
import lombok.Setter;
1417

@@ -43,7 +46,6 @@ public class PhaseData {
4346
* The status field
4447
*/
4548
@Getter
46-
@Setter
4749
private String status;
4850

4951
/**
@@ -137,4 +139,14 @@ public class PhaseData {
137139
@Getter
138140
@Setter
139141
private String updatedBy;
142+
143+
/**
144+
* Remove the whitespace from both ends and assign the value
145+
*
146+
* @param status
147+
* the status to set
148+
*/
149+
public void setStatus(String status) {
150+
this.status = StringUtils.trim(status);
151+
}
140152
}

src/main/java/com/appirio/service/challengefeeder/api/challengelisting/ChallengeListingData.java

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
import java.util.List;
88
import java.util.Set;
99

10+
import org.apache.commons.lang3.StringUtils;
11+
1012
import com.appirio.service.challengefeeder.api.FileTypeData;
1113
import com.appirio.service.challengefeeder.api.IdentifiableData;
1214
import com.appirio.service.challengefeeder.api.PhaseData;
@@ -71,7 +73,6 @@ public class ChallengeListingData extends IdentifiableData {
7173
* The status field
7274
*/
7375
@Getter
74-
@Setter
7576
private String status;
7677

7778
/**
@@ -447,7 +448,7 @@ public class ChallengeListingData extends IdentifiableData {
447448
* @param track
448449
*/
449450
public void setTrack(String track) {
450-
this.track = track.trim();
451+
this.track = StringUtils.trim(track);
451452
}
452453

453454
/**
@@ -472,4 +473,11 @@ public void setSubTrack(String subTrack) {
472473
public void setSubTrackFromEnum(SubTrack subTrackE) {
473474
this.subTrack = subTrackE.toString();
474475
}
476+
477+
/**
478+
* @param status the status to set
479+
*/
480+
public void setStatus(String status) {
481+
this.status = StringUtils.trim(status);
482+
}
475483
}

0 commit comments

Comments
 (0)