Problem
On the update path (existing mentee, looked up by email), the service calls ProfileStatus.getStatusId() on the request's profileStatus field. The mentee form on the website don't send this field, so on any second submission or the submission from the mentee who participate in long-term for the same email the call dereferences null and the request fails with a generic 500 Internal Server Error.
Evidence
Second POST /mentees against the same email, without profileStatus:
{
"timestamp": "...",
"status": 500,
"error": "Internal Server Error",
"path": "/api/platform/v1/mentees"
}
Server log:
java.lang.NullPointerException: Cannot invoke
"com.wcc.platform.domain.platform.member.ProfileStatus.getStatusId()"
because "profileStatus" is null
Adding "profileStatus": "PENDING" to the body lets the same request succeed (201).
Problem
On the update path (existing mentee, looked up by email), the service calls
ProfileStatus.getStatusId()on the request'sprofileStatusfield. The mentee form on the website don't send this field, so on any second submission or the submission from the mentee who participate in long-term for the same email the call dereferences null and the request fails with a generic500 Internal Server Error.Evidence
Second
POST /menteesagainst the same email, withoutprofileStatus:{ "timestamp": "...", "status": 500, "error": "Internal Server Error", "path": "/api/platform/v1/mentees" }Server log:
Adding
"profileStatus": "PENDING"to the body lets the same request succeed (201).