[libcalamaresui] Only load config file if there is one
- finally, no more warnings for modules that are NO_CONFIG (or noconfig: true) and don't have a config file.
This commit is contained in:
parent
f366e3840f
commit
83ffbd5126
@ -155,14 +155,17 @@ Module::fromDescriptor( const Calamares::ModuleSystem::Descriptor& moduleDescrip
|
||||
}
|
||||
|
||||
m->initFrom( moduleDescriptor );
|
||||
try
|
||||
if ( !configFileName.isEmpty() )
|
||||
{
|
||||
m->loadConfigurationFile( configFileName );
|
||||
}
|
||||
catch ( YAML::Exception& e )
|
||||
{
|
||||
cError() << "YAML parser error " << e.what();
|
||||
return nullptr;
|
||||
try
|
||||
{
|
||||
m->loadConfigurationFile( configFileName );
|
||||
}
|
||||
catch ( YAML::Exception& e )
|
||||
{
|
||||
cError() << "YAML parser error " << e.what();
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
return m.release();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user