@@ -752,7 +752,7 @@ public List<IssuesForm> getIssueForms()
752752 for (String prop : rec .keySet ())
753753 {
754754 Object value = rec .get (prop );
755- stringMap .put (prop , value .toString ());
755+ stringMap .put (prop , JSONObject . NULL . equals ( value ) ? null : value .toString ());
756756 }
757757 form .setStrings (stringMap );
758758 _issueForms .add (form );
@@ -817,11 +817,13 @@ public void validateForm(IssuesApiForm form, Errors errors)
817817 Map <String , Object > prevIssueProps = prevIssue == null ? Collections .emptyMap () : prevIssue .getProperties ();
818818
819819 Map <String , String > stringMap = new CaseInsensitiveHashMap <>(issuesForm .getStrings ());
820- for (PropertyStorageSpec prop : kind . getRequiredProperties ())
820+ for (DomainProperty prop : issueListDef . getDomain ( getUser ()). getProperties ())
821821 {
822822 if (!IssueDefDomainKind .RESOLUTION_LOOKUP .equalsIgnoreCase (prop .getName ()))
823823 stringMap .computeIfAbsent (prop .getName (), (propName ) -> Objects .toString (prevIssueProps .get (propName ), null ));
824824 }
825+ // Be sure that the posted values take precedence, even if they're null
826+ stringMap .putAll (issuesForm .getStrings ());
825827 issuesForm .setStrings (stringMap );
826828 }
827829 IssueObject issue = issuesForm .getBean ();
@@ -844,7 +846,7 @@ public ApiResponse execute(IssuesApiForm form, BindException errors) throws Exce
844846 {
845847 Issue .action action = getAction (issuesForm );
846848
847- if (action != Issue .action .insert )
849+ if (action != Issue .action .insert )
848850 {
849851 // if we are updating an existing issue pull in existing values
850852 IssueObject prevIssue = IssueManager .getIssue (getContainer (), getUser (), issuesForm .getIssueId ());
0 commit comments