Launcher add-ons: drop missing paths on load
Don’t probe for, or pass, missing paths to FlightGear. Since we don’t show such paths in the UI, they hang around forever, causing exceptions Sentry-Id: FLIGHTGEAR-NG
This commit is contained in:
parent
e62c64859c
commit
3c1594ead4
1 changed files with 5 additions and 1 deletions
|
@ -72,9 +72,13 @@ AddOnsController::AddOnsController(LauncherMainWindow *parent, LaunchConfig* con
|
|||
settings.setArrayIndex(i);
|
||||
|
||||
QString path = settings.value("path").toString();
|
||||
m_addonModulePaths.push_back( path );
|
||||
const SGPath addonPath(path.toStdString());
|
||||
if (!addonPath.exists()) {
|
||||
// drop non-existing paths on load
|
||||
continue;
|
||||
}
|
||||
|
||||
m_addonModulePaths.push_back( path );
|
||||
bool enable = settings.value("enable").toBool();
|
||||
|
||||
try {
|
||||
|
|
Loading…
Reference in a new issue