This commit is contained in:
Eugene Livis 2021-08-30 15:05:42 -04:00
parent 304442335c
commit ab30a1da8b

View File

@ -1,7 +1,7 @@
/* /*
* Autopsy Forensic Browser * Autopsy Forensic Browser
* *
* Copyright 2011-2018 Basis Technology Corp. * Copyright 2011-2021 Basis Technology Corp.
* Contact: carrier <at> sleuthkit <dot> org * Contact: carrier <at> sleuthkit <dot> org
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
@ -19,10 +19,6 @@
package org.sleuthkit.autopsy.ingest; package org.sleuthkit.autopsy.ingest;
import java.beans.PropertyChangeListener; import java.beans.PropertyChangeListener;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import org.openide.DialogDisplayer; import org.openide.DialogDisplayer;
import org.openide.NotifyDescriptor; import org.openide.NotifyDescriptor;
import org.openide.util.NbBundle; import org.openide.util.NbBundle;
@ -230,11 +226,12 @@ class ProfilePanel extends IngestModuleGlobalSettingsPanel {
/** /**
* Save a new or edited profile. * Save a new or edited profile.
*/ */
void store() { boolean store() {
if (!isValidDefinition(false)) { if (!isValidDefinition(false)) {
return; return false;
} }
saveSettings(); saveSettings();
return true;
} }
void load() { void load() {
@ -243,6 +240,8 @@ class ProfilePanel extends IngestModuleGlobalSettingsPanel {
/** /**
* Checks that information entered constitutes a valid ingest profile. * Checks that information entered constitutes a valid ingest profile.
* *
* @param dispayWarnings boolean flag whether to display warnings if an error occurred.
*
* @return true for valid, false for invalid. * @return true for valid, false for invalid.
*/ */
boolean isValidDefinition(boolean dispayWarnings) { boolean isValidDefinition(boolean dispayWarnings) {