Fix bug in g_msgids() affecting Gmail message deduplication.
Fix bug in g_msgids() affecting Gmail message deduplication.

We occasionally were failing to deduplicate message object creation or
download because we wrongly excluded messages which currently had no
associated ImapUids. (This is actually a common situation, as when a
message moves we might well delete the old ImapUid before creating the
new one.)

Fixes T180.

wakermahmud/sync-engine,gale320/sync-engine,jobscore/sync-engine,closeio/nylas,ErinCall/sync-engine,Eagles2F/sync-engine,closeio/nylas,rmasters/inbox,closeio/nylas,Eagles2F/sync-engine,nylas/sync-engine,wakermahmud/sync-engine,rmasters/inbox,wakermahmud/sync-engine,gale320/sync-engine,Eagles2F/sync-engine,gale320/sync-engine,PriviPK/privipk-sync-engine,EthanBlackburn/sync-engine,nylas/sync-engine,jobscore/sync-engine,nylas/sync-engine,PriviPK/privipk-sync-engine,ErinCall/sync-engine,Eagles2F/sync-engine,gale320/sync-engine,EthanBlackburn/sync-engine,PriviPK/privipk-sync-engine,closeio/nylas,rmasters/inbox,ErinCall/sync-engine,rmasters/inbox,ErinCall/sync-engine,wakermahmud/sync-engine,ErinCall/sync-engine,EthanBlackburn/sync-engine,PriviPK/privipk-sync-engine,PriviPK/privipk-sync-engine,Eagles2F/sync-engine,nylas/sync-engine,jobscore/sync-engine,EthanBlackburn/sync-engine,wakermahmud/sync-engine,jobscore/sync-engine,EthanBlackburn/sync-engine,gale320/sync-engine