Allow setting instance of PhutilTranslator
Summary:
I will need it for sending e-mails. The plan is this:
- Set instance to recipient's language (or server default if multiplexing is disabled).
- Build e-mails.
- Set it back.
The other option would be to give up on using pht() and inject $translator everywhere and use it instead but it seems too complex even if it would be cleaner.
Test Plan: New test.
Reviewers: epriestley
Reviewed By: epriestley
CC: aran, Korvin
Maniphest Tasks: T1139
Differential Revision: https://secure.phabricator.com/D2772