Skip to content

Commit

Permalink
GRAD2-2958 (#683)
Browse files Browse the repository at this point in the history
* GRAD2-2958
User Distribution Run downloaded report files are empty

* GRAD2-2958
User Distribution Run downloaded report files are empty
  • Loading branch information
arybakov-cgi authored Sep 13, 2024
1 parent a6147b7 commit cb33ed2
Showing 1 changed file with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import ca.bc.gov.educ.api.gradstudent.util.EducGradStudentApiConstants;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.google.gson.Gson;
import lombok.Builder;
import lombok.Data;
Expand Down Expand Up @@ -85,12 +86,12 @@ public String toJson() {
return new Gson().toJson(this);
}

@JsonIgnore
public boolean isEmpty() {
return schoolOfRecords.isEmpty() &&
districts.isEmpty() &&
schoolCategoryCodes.isEmpty() &&
pens.isEmpty() &&
studentIDs.isEmpty() &&
programs.isEmpty();
return (schoolOfRecords == null || schoolOfRecords.isEmpty()) &&
(districts == null || districts.isEmpty()) &&
(schoolCategoryCodes == null || schoolCategoryCodes.isEmpty()) &&
(pens == null || pens.isEmpty()) &&
(studentIDs == null || studentIDs.isEmpty());
}
}

0 comments on commit cb33ed2

Please sign in to comment.