From ecbf9dced8ffc721e3e63ea35a76af673a54dbbf Mon Sep 17 00:00:00 2001 From: Enquier Date: Wed, 29 May 2024 10:47:36 -0600 Subject: [PATCH] fix npe --- .../dao/FederatedProjectPersistence.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/federatedpersistence/src/main/java/org/openmbee/mms/federatedpersistence/dao/FederatedProjectPersistence.java b/federatedpersistence/src/main/java/org/openmbee/mms/federatedpersistence/dao/FederatedProjectPersistence.java index 4f12ef44c..fea5c2ddb 100644 --- a/federatedpersistence/src/main/java/org/openmbee/mms/federatedpersistence/dao/FederatedProjectPersistence.java +++ b/federatedpersistence/src/main/java/org/openmbee/mms/federatedpersistence/dao/FederatedProjectPersistence.java @@ -184,7 +184,10 @@ public ProjectJson save(ProjectJson projectJson) { proj.setOrganization(org.get()); proj.setProjectType(projectJson.getProjectType()); proj.setDocId(projectJson.getDocId()); - proj.setDeleted(projectJson.isArchived()); + + if (projectJson.isArchived() != null) { + proj.setDeleted(projectJson.isArchived()); + } try { projectDAO.save(proj);