diff --git a/oaipmh-core/src/main/java/info/textgrid/middleware/SetDeliverer.java b/oaipmh-core/src/main/java/info/textgrid/middleware/SetDeliverer.java index b01b8e4a8538df307c3e35e3bec332fc515753b0..951816bc8a639c13fa7a80030bca0e3be973389d 100644 --- a/oaipmh-core/src/main/java/info/textgrid/middleware/SetDeliverer.java +++ b/oaipmh-core/src/main/java/info/textgrid/middleware/SetDeliverer.java @@ -240,8 +240,8 @@ public class SetDeliverer { // Divide ID and title. String combined = b.getKeyAsString(); int indexOf = combined.indexOf(DH_COLLECTION_FILTER_NAME); - String id = combined.substring(0, indexOf); - String title = combined.substring(indexOf + 1); + String id = combined.substring(0, indexOf - 1); + String title = combined.substring(indexOf); // Set set. SetType newSet = new SetType(); newSet.setSetSpec(id);