Skip to content

Commit

Permalink
Added code to check for note element availability in the JsonObject. …
Browse files Browse the repository at this point in the history
…if not available setting it to null.
  • Loading branch information
RameshRapa committed Aug 16, 2023
1 parent 2d4fe8a commit 3d6943f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/org/labkey/snd/SNDController.java
Original file line number Diff line number Diff line change
Expand Up @@ -1006,7 +1006,7 @@ public ApiResponse execute(SimpleApiJsonForm form, BindException errors)
if (!errors.hasErrors())
{
String projectIdrev = json.getString("projectIdRev");
String note = json.getString("note");
String note = json.has("note") ? json.getString("note") : null;

List<EventData> eventData = null;
JSONArray eventDataJson = json.has("eventData") ? json.getJSONArray("eventData") : null;
Expand Down

0 comments on commit 3d6943f

Please sign in to comment.