Attempt to sync an UID in setChangeKey to avoid crashing

This may happen if between sync cache and setChangeKey a modSeq
is making synchroniseCache not retrieve the newly stored message.

This should fix the following crash:

https://tracker.zentyal.org/issues/2673
Never say *it cannot happen*, because it will and you know it. Nevertheless `abort()` would be the only choice here so doesn't really matter