зеркало из https://github.com/mozilla/snowl.git
if not building author collections, don't delete places record on message delete of one message/author record.
--HG-- extra : rebase_source : 933b5d35702af18078fab1a7111e65a4332a8348
This commit is contained in:
Родитель
c744e765e0
Коммит
adc7d2afa8
|
@ -149,11 +149,14 @@ SnowlMessage.delete = function(aMessage) {
|
|||
"DELETE FROM people " +
|
||||
"WHERE id = " + message.author.person.id);
|
||||
|
||||
// Finally, clean up Places bookmark by author's placeID. A collections
|
||||
// tree rebuild is triggered by Places on removeItem of a visible item,
|
||||
// triggering a select event. Need to bypass in onSelect.
|
||||
SnowlMessage.prototype.CollectionsView.noSelect = true;
|
||||
PlacesUtils.bookmarks.removeItem(message.author.person.placeID);
|
||||
// Finally, clean up Places bookmark by author's placeID. If authors
|
||||
// collections are not being built, placeID will be null, so skip.
|
||||
// A collections tree rebuild is triggered by Places on removeItem of a
|
||||
// visible item, triggering a select event. Need to bypass in onSelect.
|
||||
if (message.author.person.placeID) {
|
||||
SnowlMessage.prototype.CollectionsView.noSelect = true;
|
||||
PlacesUtils.bookmarks.removeItem(message.author.person.placeID);
|
||||
}
|
||||
}
|
||||
|
||||
SnowlDatastore.dbConnection.commitTransaction();
|
||||
|
|
Загрузка…
Ссылка в новой задаче