Skip to content

Commit c9d33e2

Browse files
committed
Handle posting same JSON twice.
1 parent 4b6c367 commit c9d33e2

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/main/java/edu/harvard/iq/dataverse/LicenseServiceBean.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ public License getByName(String name) throws FetchException {
5555
public License save(License license) throws PersistenceException, RequestBodyException {
5656
if (license.getId() == null) {
5757
em.persist(license);
58+
em.flush();
5859
return license;
5960
} else {
6061
throw new RequestBodyException("There shouldn't be an ID in the request body");

0 commit comments

Comments
 (0)