avniproject / avni-client

Android app for the fieldworkers.
https://avniproject.org
GNU Affero General Public License v3.0
7 stars 21 forks source link

Sync issue #1542

Open mahalakshme opened 3 weeks ago

mahalakshme commented 3 weeks ago

https://avni.freshdesk.com/a/tickets/4878

app: 10.0.3, 9.4.0 username: mubarak@hd_utthaan env: prod

Image

Bugsnag link: https://app.bugsnag.com/samanvay-research-and-development-foundation/avni-client/errors/671f19e3b73b2f0a14a61927?i=em&m=fq&pivot_tab=user.id

petmongrels commented 3 weeks ago

dump kept in user media. it starts with Kept...

other details

Analysis

petmongrels commented 3 weeks ago

Individual.initLowestAddressLevel should be changed to following otherwise it returns false instead of returning null.

static initLowestAddressLevel(lowestAddressLevel, subjectType, entityService) { const isUserSubjectType = subjectType && subjectType.isUser(); const noAddress = _.isNil(lowestAddressLevel); if (noAddress) { return isUserSubjectType ? this.getPlaceholderAddressLevel(entityService) : null; } return lowestAddressLevel; }