Send mail to targets in the user's translation

Summary: Ref T6367.

Test Plan:
  - Added and executed unit tests.
  - Sent mail to A (en_US) and B (en_A*).
  - Got one mail in English and one mail in ENGLISH.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T6367

Differential Revision: https://secure.phabricator.com/D13142
This commit is contained in:
epriestley
2015-06-03 10:49:27 -07:00
parent 6db97bde12
commit 069e60d2ff
7 changed files with 117 additions and 7 deletions

View File

@@ -114,10 +114,7 @@ abstract class PhabricatorController extends AphrontController {
$request->setUser($user);
}
$locale_code = $user->getTranslation();
if ($locale_code) {
PhabricatorEnv::setLocaleCode($locale_code);
}
PhabricatorEnv::setLocaleCode($user->getTranslation());
$preferences = $user->loadPreferences();
if (PhabricatorEnv::getEnvConfig('darkconsole.enabled')) {