diff --git a/build.gradle b/build.gradle
index eff53058..b6c4a91a 100644
--- a/build.gradle
+++ b/build.gradle
@@ -11,7 +11,7 @@ buildscript {
}
}
-version "1.4.2.1"
+version "1.4.2.2"
group "au.org.ala"
apply plugin:"eclipse"
@@ -73,7 +73,7 @@ dependencies {
compile 'org.grails.plugins:external-config:1.1.1'
compile group: 'org.grails.plugins', name: 'ala-bootstrap3', version: '3.0.3'
- compile(group: 'org.grails.plugins', name: 'ala-auth', version:'3.1.0') {
+ compile(group: 'org.grails.plugins', name: 'ala-auth', version:'3.0.4') {
exclude group: 'javax.servlet', module: 'servlet-api'
}
compile group: 'org.grails.plugins', name: 'ala-admin-plugin', version: '2.0'
diff --git a/grails-app/services/au/org/ala/bie/ImportService.groovy b/grails-app/services/au/org/ala/bie/ImportService.groovy
index 050881a8..bfb2a71d 100644
--- a/grails-app/services/au/org/ala/bie/ImportService.groovy
+++ b/grails-app/services/au/org/ala/bie/ImportService.groovy
@@ -2149,9 +2149,9 @@ class ImportService {
return nameFormatted
if (nameComplete) {
def authorIndex = scientificNameAuthorship ? nameComplete.indexOf(scientificNameAuthorship) : -1
- if (authorIndex < 0)
+ if (authorIndex <= 0)
return "${StringEscapeUtils.escapeHtml(nameComplete)}"
- def preAuthor = nameComplete.substring(0, authorIndex - 1).trim()
+ def preAuthor = nameComplete.substring(0, authorIndex).trim()
def postAuthor = nameComplete.substring(authorIndex + scientificNameAuthorship.length()).trim()
def name = ""
if (preAuthor && !preAuthor.isEmpty())