Closed ydrozhdzhal closed 4 years ago
Looks like there could potentially be an issue when MailChimpList#addOrUpdateMember(Member) is called with a partially constructed Member (i.e. no status is provided). When no status is supplied the expected behavior for an existing member is for the status to remain unchanged. StatusIfNew will be used when a new member is created and no status is provided. After a code review it looks like the above mentioned line could throw an unexpected null pointer exception under some circumstances.
https://github.com/banana-j/bananaj/blob/21ac5d5528abb763b1c3483a303fdf9128308181/src/main/java/com/github/alexanderwe/bananaj/model/list/member/Member.java#L728
As I understood from API docs this field is not required for new member and can be taken from StatusIfNew field.