Delete from addressbook only by address (Fixes: #1484)

This commit is contained in:
Dmitri Bogomolov 2019-09-23 17:53:59 +03:00
parent 4c7f9487e2
commit 7d0e23e31a
Signed by untrusted user: g1itch
GPG Key ID: 720A756F18DEED13

View File

@ -3191,8 +3191,7 @@ class MyForm(settingsmixin.SMainWindow):
0].row()
item = self.ui.tableWidgetAddressBook.item(currentRow, 0)
sqlExecute(
'DELETE FROM addressbook WHERE label=? AND address=?',
item.label, item.address)
'DELETE FROM addressbook WHERE address=?', item.address)
self.ui.tableWidgetAddressBook.removeRow(currentRow)
self.rerenderMessagelistFromLabels()
self.rerenderMessagelistToLabels()