Allow messages to be designated either by their number or their UID.

Warning: this is an API-breaking change.