mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 04:52:07 -08:00
Some minor changes.
This commit is contained in:
parent
6df19bd718
commit
24470a4abf
3 changed files with 8 additions and 6 deletions
|
|
@ -53,6 +53,7 @@ public class RepositoryUtil {
|
|||
}
|
||||
|
||||
public static long getDatabaseVersion(ConnectionSource connectionSource, String entityName) throws SQLException {
|
||||
TableUtils.createTableIfNotExists(connectionSource, DatabaseVersion.class);
|
||||
Dao<DatabaseVersion, Object> dbVersionDao = DaoManager.createDao(connectionSource, DatabaseVersion.class);
|
||||
|
||||
QueryBuilder<DatabaseVersion, Object> queryBuilder = dbVersionDao.queryBuilder();
|
||||
|
|
@ -61,9 +62,8 @@ public class RepositoryUtil {
|
|||
if (dbVersions.isEmpty()) {
|
||||
return 0;
|
||||
} else {
|
||||
return dbVersions.get(0). getVersion();
|
||||
return dbVersions.get(0).getVersion();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue