diff --git a/src/main/java/org/jenkinsci/plugins/liquibase/builder/AbstractLiquibaseBuilder.java b/src/main/java/org/jenkinsci/plugins/liquibase/builder/AbstractLiquibaseBuilder.java index 8c1cd4f..b62d074 100644 --- a/src/main/java/org/jenkinsci/plugins/liquibase/builder/AbstractLiquibaseBuilder.java +++ b/src/main/java/org/jenkinsci/plugins/liquibase/builder/AbstractLiquibaseBuilder.java @@ -124,7 +124,7 @@ public void perform(@Nonnull Run build, if (!Strings.isNullOrEmpty(installation.getDatabaseDriverUrl())) { Iterable urls = Splitter.on(",").trimResults().split(installation.getDatabaseDriverUrl()); for (String url : urls) { - String filename = url.substring(installation.getDatabaseDriverUrl().lastIndexOf("/") + 1); + String filename = url.substring(url.lastIndexOf("/") + 1); File localJar = new File(installation.getHome(), "lib/" + filename); if (!localJar.exists()) { log.println("Downloading " + url + " to " + localJar);