Handle missing setting gracefully.

main
Teo Mrnjavac 9 years ago
parent 7b3f6cdd5a
commit 1d8330f1eb

@ -149,7 +149,7 @@ Settings::Settings( const QString& settingsFilePath,
.as< std::string >() ); .as< std::string >() );
m_promptInstall = config[ "prompt-install" ].as< bool >(); m_promptInstall = config[ "prompt-install" ].as< bool >();
m_doChroot = !config[ "dont-chroot" ].as< bool >(); m_doChroot = config[ "dont-chroot" ] ? !config[ "dont-chroot" ].as< bool >() : true;
} }
catch ( YAML::Exception& e ) catch ( YAML::Exception& e )
{ {

Loading…
Cancel
Save