Enable debug only if ImapDebugEnabled is enabled

It would probably be better to replace ImapDebugEnabled by something like
MailDebugEnabled. But this is certainly better than always having debug output