Address review comments

This commit is contained in:
Raman 2018-08-15 12:01:01 -04:00
parent 63860fd551
commit ae5621db16
3 changed files with 2 additions and 5 deletions

View File

@ -401,8 +401,7 @@ public final class ImageGalleryController {
*/ */
public void rebuildDB() { public void rebuildDB() {
// queue a rebuild task for each stale data source // queue a rebuild task for each stale data source
Set<Long> staleDataSources = getStaleDataSourceIds(); getStaleDataSourceIds().forEach((dataSourceObjId) -> {
staleDataSources.forEach((dataSourceObjId) -> {
queueDBTask(new CopyAnalyzedFiles(dataSourceObjId, instance, db, sleuthKitCase)); queueDBTask(new CopyAnalyzedFiles(dataSourceObjId, instance, db, sleuthKitCase));
}); });
} }

View File

@ -40,8 +40,6 @@ class PerCaseProperties {
public static final String ENABLED = "enabled"; //NON-NLS public static final String ENABLED = "enabled"; //NON-NLS
public static final String STALE = "stale"; //NON-NLS
private final Case theCase; private final Case theCase;
PerCaseProperties(Case c) { PerCaseProperties(Case c) {

View File

@ -786,7 +786,7 @@ public final class DrawableDB {
statement = con.createStatement(); statement = con.createStatement();
rs = statement.executeQuery("SELECT ds_obj_id, drawable_db_build_status FROM datasources "); //NON-NLS rs = statement.executeQuery("SELECT ds_obj_id, drawable_db_build_status FROM datasources "); //NON-NLS
while (rs.next()) { while (rs.next()) {
map.put(rs.getLong(1), DrawableDbBuildStatusEnum.valueOf(rs.getString(2))); map.put(rs.getLong("ds_obj_id"), DrawableDbBuildStatusEnum.valueOf(rs.getString("drawable_db_build_status")));
} }
} catch (SQLException e) { } catch (SQLException e) {
throw new TskCoreException("SQLException while getting data source object ids", e); throw new TskCoreException("SQLException while getting data source object ids", e);