diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-06-19 11:00:39 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-06-19 12:27:01 +0200 |
commit | 49b83e87e4da54cdd18ec04b10fdb4624389bd80 (patch) | |
tree | d87a11bcb14e6ef3811df53c06aeb1726616a26c /common/mail/threadindexer.h | |
parent | b940489ed6afe413339a1c602d05f3b4f3133463 (diff) | |
download | sink-49b83e87e4da54cdd18ec04b10fdb4624389bd80.tar.gz sink-49b83e87e4da54cdd18ec04b10fdb4624389bd80.zip |
Fixed the thread index.
* Modifications could result in index changes because we lost the
threadId due to remove + add. A modify was necessary (although we can
ignore it for the email case).
* The ThreadIndexer would try to lookup and potentially index threads
for empty parent ids, which is clearly wrong.
Diffstat (limited to 'common/mail/threadindexer.h')
-rw-r--r-- | common/mail/threadindexer.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/common/mail/threadindexer.h b/common/mail/threadindexer.h index b2e939a..747ba77 100644 --- a/common/mail/threadindexer.h +++ b/common/mail/threadindexer.h | |||
@@ -27,10 +27,11 @@ class ThreadIndexer : public Indexer | |||
27 | public: | 27 | public: |
28 | typedef QSharedPointer<ThreadIndexer> Ptr; | 28 | typedef QSharedPointer<ThreadIndexer> Ptr; |
29 | virtual void add(const ApplicationDomain::ApplicationDomainType &entity) Q_DECL_OVERRIDE; | 29 | virtual void add(const ApplicationDomain::ApplicationDomainType &entity) Q_DECL_OVERRIDE; |
30 | virtual void modify(const ApplicationDomain::ApplicationDomainType &oldEntity, const ApplicationDomain::ApplicationDomainType &newEntity) Q_DECL_OVERRIDE; | ||
30 | virtual void remove(const ApplicationDomain::ApplicationDomainType &entity) Q_DECL_OVERRIDE; | 31 | virtual void remove(const ApplicationDomain::ApplicationDomainType &entity) Q_DECL_OVERRIDE; |
31 | static QMap<QByteArray, int> databases(); | 32 | static QMap<QByteArray, int> databases(); |
32 | private: | 33 | private: |
33 | void updateThreadingIndex(const QByteArray &identifier, const ApplicationDomain::ApplicationDomainType &entity, Sink::Storage::DataStore::Transaction &transaction); | 34 | void updateThreadingIndex(const ApplicationDomain::ApplicationDomainType &entity, Sink::Storage::DataStore::Transaction &transaction); |
34 | }; | 35 | }; |
35 | 36 | ||
36 | } | 37 | } |