diff --git a/src/com/rjconsultores/ventaboletos/FlyWay.java b/src/com/rjconsultores/ventaboletos/FlyWay.java index 87e0d14a0..14ad8e25d 100644 --- a/src/com/rjconsultores/ventaboletos/FlyWay.java +++ b/src/com/rjconsultores/ventaboletos/FlyWay.java @@ -77,7 +77,10 @@ public class FlyWay { try{ final Flyway flyway = new Flyway(); - flyway.setLocations(this.location); + if (this.location != null && !this.location.equals("db.migration")) { + flyway.setLocations(this.location); + } + flyway.setDataSource(dataSource); execute(flyway); @@ -98,8 +101,11 @@ public class FlyWay { try{ final Flyway flyway = new Flyway(); - - flyway.setLocations("classpath: " + this.location); + + if (this.location != null && !this.location.equals("db.migration")) { + flyway.setLocations("classpath: " + this.location); + } + flyway.setDataSource(url, user, password); execute(flyway);