mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2026-11-02 11:37:37 +00:00
修正
This commit is contained in:
1 file changed
+3
-3
@@ -159,7 +159,7 @@ public class LacertaVcsImpl implements LacertaVcs {
|
|||||||
ArrayList<VcsLogModel> vcsLogModels = new ArrayList<>();
|
ArrayList<VcsLogModel> vcsLogModels = new ArrayList<>();
|
||||||
|
|
||||||
VcsRevEntity vcsRevEntity = database.vcsRevDao().findById(revId);
|
VcsRevEntity vcsRevEntity = database.vcsRevDao().findById(revId);
|
||||||
ArrayList<VcsLogEntity> vcsLogEntities = getLogInRev(vcsRevEntity);
|
ArrayList<VcsLogEntity> vcsLogEntities = getLogInRevAsync(vcsRevEntity).join(); // TODO-rca: リファクタリング
|
||||||
vcsLogEntities.forEach(vcsLogEntity -> {
|
vcsLogEntities.forEach(vcsLogEntity -> {
|
||||||
VcsLogModel vcsLogModel = new VcsLogModel();
|
VcsLogModel vcsLogModel = new VcsLogModel();
|
||||||
vcsLogModel.setId(vcsLogEntity.id);
|
vcsLogModel.setId(vcsLogEntity.id);
|
||||||
@@ -201,8 +201,8 @@ public class LacertaVcsImpl implements LacertaVcs {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private ArrayList<VcsLogEntity> getLogInRev(VcsRevEntity revEntity) {
|
private CompletableFuture<ArrayList<VcsLogEntity>> getLogInRevAsync(VcsRevEntity revEntity) {
|
||||||
return new ArrayList<>(database.vcsLogDao().findByIds(revEntity.logIds));
|
return CompletableFuture.supplyAsync(() -> new ArrayList<>(database.vcsLogDao().findByIds(revEntity.logIds)));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in new issue
Block a user