Fix loading custom device

This commit is contained in:
Jonas Kvinge 2018-10-22 22:10:27 +02:00
parent 3a02ece169
commit c8dfb9b0db
1 changed files with 1 additions and 1 deletions

View File

@ -316,7 +316,7 @@ void BackendSettingsPage::Load_Device(QString output, QVariant device) {
bool found(false);
for (int i = 0; i < ui_->combobox_device->count(); ++i) {
QVariant d = ui_->combobox_device->itemData(i).value<QVariant>();
if (df_device.value == d) {
if (df_device.value.isValid() && df_device.value == d) {
ui_->combobox_device->setCurrentIndex(i);
found = true;
break;