diff --git a/dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/tracker/imports/note/JdbcNoteStore.java b/dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/tracker/imports/note/JdbcNoteStore.java index 0d9ba9ce426..2e6eec1ebcc 100644 --- a/dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/tracker/imports/note/JdbcNoteStore.java +++ b/dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/tracker/imports/note/JdbcNoteStore.java @@ -87,7 +87,7 @@ boolean exists(@Nonnull UID note) { "select count(1) from note where uid = :uid", Map.of("uid", note.getValue()), Integer.class); - return count == null || count > 0; + return count != null && count > 0; } private long saveNote(@Nonnull Note note, @Nonnull UserDetails user) {