From cb8fb55dcabf27319ae2c03d64ec108e85b78e39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michel=20Kr=C3=A4mer?= Date: Thu, 15 Jul 2021 08:37:31 +0200 Subject: [PATCH] Update citeproc-java to 3.0.0-alpha.2 (#7911) --- build.gradle | 2 +- external-libraries.md | 2 +- src/main/java/org/jabref/logic/citationstyle/CSLAdapter.java | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/build.gradle b/build.gradle index abecbb2f0e6..92831f62c9a 100644 --- a/build.gradle +++ b/build.gradle @@ -186,7 +186,7 @@ dependencies { implementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '3.0.0-SNAPSHOT' annotationProcessor group: 'org.apache.logging.log4j', name: 'log4j-core', version: '3.0.0-SNAPSHOT' - implementation 'de.undercouch:citeproc-java:3.0.0-alpha.1' + implementation 'de.undercouch:citeproc-java:3.0.0-alpha.2' implementation group: 'jakarta.activation', name: 'jakarta.activation-api', version: '1.2.1' implementation group: 'jakarta.xml.bind', name: 'jakarta.xml.bind-api', version: '2.3.2' diff --git a/external-libraries.md b/external-libraries.md index add09f3b076..7d10d263826 100644 --- a/external-libraries.md +++ b/external-libraries.md @@ -539,7 +539,7 @@ commons-codec:commons-codec:1.11 commons-logging:commons-logging:1.2 de.saxsys:mvvmfx-validation:1.9.0-SNAPSHOT de.saxsys:mvvmfx:1.8.0 -de.undercouch:citeproc-java:3.0.0-alpha.1 +de.undercouch:citeproc-java:3.0.0-alpha.2 eu.lestard:doc-annotations:0.2 info.debatty:java-string-similarity:2.0.0 io.github.java-diff-utils:java-diff-utils:4.10 diff --git a/src/main/java/org/jabref/logic/citationstyle/CSLAdapter.java b/src/main/java/org/jabref/logic/citationstyle/CSLAdapter.java index 5edac0f1f6b..a831e074552 100644 --- a/src/main/java/org/jabref/logic/citationstyle/CSLAdapter.java +++ b/src/main/java/org/jabref/logic/citationstyle/CSLAdapter.java @@ -3,6 +3,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.Arrays; +import java.util.Collection; import java.util.List; import java.util.Objects; @@ -124,10 +125,10 @@ public CSLItemData retrieveItem(String id) { } @Override - public String[] getIds() { + public Collection getIds() { return data.stream() .map(entry -> entry.getCitationKey().orElse("")) - .toArray(String[]::new); + .toList(); } } }