Skip to content

Commit 61774f8

Browse files
committed
Merge pull request #3855
0fde3bb [Qt] Fill in label from address book also for URIs (Cozz Lovan)
2 parents 5b6e981 + 0fde3bb commit 61774f8

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/qt/sendcoinsentry.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,10 @@ void SendCoinsEntry::setValue(const SendCoinsRecipient &value)
195195
ui->messageTextLabel->setVisible(!recipient.message.isEmpty());
196196
ui->messageLabel->setVisible(!recipient.message.isEmpty());
197197

198-
ui->payTo->setText(recipient.address);
199-
ui->addAsLabel->setText(recipient.label);
198+
ui->addAsLabel->clear();
199+
ui->payTo->setText(recipient.address); // this may set a label from addressbook
200+
if (!recipient.label.isEmpty()) // if a label had been set from the addressbook, dont overwrite with an empty label
201+
ui->addAsLabel->setText(recipient.label);
200202
ui->payAmount->setValue(recipient.amount);
201203
}
202204
}

0 commit comments

Comments
 (0)