Don't call a virtual method from constructor

Authored by jkt on Jun 29 2018, 12:37 AM.

Description

Don't call a virtual method from constructor

The intention of that check was to prevent issuing a FETCH for parts
which have no fetchable content on their own (in IMAP terms). Having
that in place in constructor was just an optimization.

Let's move this into fetch() to prevent any confusion about consulting a
parent class type's implementation accidentally.

Thanks to lgtm.com for a nice catch.

Change-Id: I67097ee1e8fd8dec6dc5294add6956d01892dc78
Fixes: https://lgtm.com/projects/g/KDE/trojita/snapshot/20e1eb1eb357b662c07be39780d032d58e60ec7a/files/src/Imap/Model/MailboxTree.cpp#x58a977bed141c12b:1

Details

Committed
jktJun 29 2018, 12:50 AM
Parents
R546:272c3c0435f1: Merge changes from topic 'imap-wrong-bodystructure'
Branches
Unknown
Tags
Unknown
References
refs/changes/04/1004/1