Don't filter out duplicated entries from places panel

This can lead to crashes and is inconsistent with the KIO file picker dialog, which shows duplicated entries.
BUG: 393528

Differential Revision: https://phabricator.kde.org/D12558
This commit is contained in:
Antonio Rojas 2018-04-29 19:39:15 +02:00
parent 78c8b36dd8
commit 0c05b992c0

View file

@ -397,10 +397,7 @@ void PlacesItemModel::addItemFromSourceModel(const QModelIndex &index)
const KBookmark bookmark = m_sourceModel->bookmarkForIndex(index);
Q_ASSERT(!bookmark.isNull());
PlacesItem *item = itemFromBookmark(bookmark);
if (!item) {
item = new PlacesItem(bookmark);
}
PlacesItem *item = new PlacesItem(bookmark);
updateItem(item, index);
insertSortedItem(item);