1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-08 16:02:40 +01:00

Remove product literal strings in "pht()", part 11

Summary: Ref T13658.

Test Plan: Static checks only, none of these looked easily reachable.

Subscribers: PHID-OPKG-gm6ozazyms6q6i22gyam

Maniphest Tasks: T13658

Differential Revision: https://secure.phabricator.com/D21777
This commit is contained in:
epriestley 2022-04-25 13:04:49 -07:00
parent adcc063242
commit 039cbec155
12 changed files with 45 additions and 40 deletions

View file

@ -7,8 +7,8 @@ $table_name = 'user_oauthinfo';
foreach (new LiskRawMigrationIterator($conn, $table_name) as $row) { foreach (new LiskRawMigrationIterator($conn, $table_name) as $row) {
throw new Exception( throw new Exception(
pht( pht(
'Your Phabricator install has ancient OAuth account data and is '. 'This database has ancient OAuth account data and is too old to '.
'too old to upgrade directly to a modern version of Phabricator. '. 'upgrade directly to a modern software version. Upgrade to a version '.
'Upgrade to a version released between June 2013 and February 2019 '. 'released between June 2013 and February 2019 first, then upgrade to '.
'first, then upgrade to a modern version.')); 'a modern version.'));
} }

View file

@ -7,8 +7,8 @@ $table_name = 'user_ldapinfo';
foreach (new LiskRawMigrationIterator($conn, $table_name) as $row) { foreach (new LiskRawMigrationIterator($conn, $table_name) as $row) {
throw new Exception( throw new Exception(
pht( pht(
'Your Phabricator install has ancient LDAP account data and is '. 'This database has ancient LDAP account data and is too old to upgrade '.
'too old to upgrade directly to a modern version of Phabricator. '. 'directly to a modern version of the software. Upgrade to a version '.
'Upgrade to a version released between June 2013 and February 2019 '. 'released between June 2013 and February 2019 first, then upgrade to a '.
'first, then upgrade to a modern version.')); 'modern version.'));
} }

View file

@ -122,9 +122,9 @@ if ($is_svnrevprop) {
if (!strlen($username)) { if (!strlen($username)) {
throw new Exception( throw new Exception(
pht( pht(
'No Direct Pushes: You are pushing directly to a repository hosted '. 'No Direct Pushes: You are pushing directly to a hosted repository. '.
'by Phabricator. This will not work. See "No Direct Pushes" in the '. 'This will not work. See "No Direct Pushes" in the documentation '.
'documentation for more information.')); 'for more information.'));
} }
if ($repository->isHg()) { if ($repository->isHg()) {

View file

@ -354,9 +354,9 @@ final class AphrontRequest extends Phobject {
$info = array(); $info = array();
$info[] = pht( $info[] = pht(
'You are trying to save some data to Phabricator, but the request '. 'You are trying to save some data to permanent storage, but the '.
'your browser made included an incorrect token. Reload the page '. 'request your browser made included an incorrect token. Reload the '.
'and try again. You may need to clear your cookies.'); 'page and try again. You may need to clear your cookies.');
if ($this->isAjax()) { if ($this->isAjax()) {
$info[] = pht('This was an Ajax request.'); $info[] = pht('This was an Ajax request.');
@ -587,11 +587,11 @@ final class AphrontRequest extends Phobject {
throw new AphrontMalformedRequestException( throw new AphrontMalformedRequestException(
pht('Bad Host Header'), pht('Bad Host Header'),
pht( pht(
'This Phabricator install is configured as "%s", but you are '. 'This server is configured as "%s", but you are using the domain '.
'using the domain name "%s" to access a page which is trying to '. 'name "%s" to access a page which is trying to set a cookie. '.
'set a cookie. Access Phabricator on the configured primary '. 'Access this service on the configured primary domain or a '.
'domain or a configured alternate domain. Phabricator will not '. 'configured alternate domain. Cookies will not be set on other '.
'set cookies on other domains for security reasons.', 'domains for security reasons.',
$configured_as, $configured_as,
$accessed_as), $accessed_as),
true); true);

View file

@ -419,9 +419,9 @@ final class AphrontApplicationConfiguration
throw new AphrontMalformedRequestException( throw new AphrontMalformedRequestException(
pht('No %s', 'SERVER_ADDR'), pht('No %s', 'SERVER_ADDR'),
pht( pht(
'Phabricator is configured to operate in cluster mode, but '. 'This service is configured to operate in cluster mode, but '.
'%s is not defined in the request context. Your webserver '. '%s is not defined in the request context. Your webserver '.
'configuration needs to forward %s to PHP so Phabricator can '. 'configuration needs to forward %s to PHP so the software can '.
'reject requests received on external interfaces.', 'reject requests received on external interfaces.',
'SERVER_ADDR', 'SERVER_ADDR',
'SERVER_ADDR')); 'SERVER_ADDR'));
@ -431,7 +431,7 @@ final class AphrontApplicationConfiguration
throw new AphrontMalformedRequestException( throw new AphrontMalformedRequestException(
pht('External Interface'), pht('External Interface'),
pht( pht(
'Phabricator is configured in cluster mode and the address '. 'This service is configured in cluster mode and the address '.
'this request was received on ("%s") is not whitelisted as '. 'this request was received on ("%s") is not whitelisted as '.
'a cluster address.', 'a cluster address.',
$server_addr)); $server_addr));

View file

@ -147,10 +147,9 @@ final class AlmanacManagementRegisterWorkflow
if (!$public_key) { if (!$public_key) {
throw new PhutilArgumentUsageException( throw new PhutilArgumentUsageException(
pht( pht(
'The public key corresponding to the given private key is not '. 'The public key corresponding to the given private key is unknown. '.
'yet known to Phabricator. Associate the public key with an '. 'Associate the public key with an Almanac device in the web '.
'Almanac device in the web interface before registering hosts '. 'interface before registering hosts with it.'));
'with it.'));
} }
if ($public_key->getObjectPHID() !== $device->getPHID()) { if ($public_key->getObjectPHID() !== $device->getPHID()) {

View file

@ -61,14 +61,14 @@ final class AlmanacManagementTrustKeyWorkflow
phutil_console_wrap( phutil_console_wrap(
pht( pht(
'Trusting a public key gives anyone holding the corresponding '. 'Trusting a public key gives anyone holding the corresponding '.
'private key complete, unrestricted access to all data in '. 'private key complete, unrestricted access to all data. The '.
'Phabricator. The private key will be able to sign requests that '. 'private key will be able to sign requests that bypass policy and '.
'skip policy and security checks.')), 'security checks.')),
phutil_console_wrap( phutil_console_wrap(
pht( pht(
'This is an advanced feature which should normally be used only '. 'This is an advanced feature which should normally be used only '.
'when building a Phabricator cluster. This feature is very '. 'when building a cluster. This feature is very dangerous if '.
'dangerous if misused.')), 'misused.')),
pht('This key is associated with device "%s".', $handle->getName())); pht('This key is associated with device "%s".', $handle->getName()));
$prompt = pht( $prompt = pht(

View file

@ -54,8 +54,9 @@ final class PhabricatorAuthConfirmLinkController
), ),
pht( pht(
'Confirm the link with this %s account. This account will be '. 'Confirm the link with this %s account. This account will be '.
'able to log in to your Phabricator account.', 'able to log in to your %s account.',
$provider->getProviderName()))) $provider->getProviderName(),
PlatformSymbols::getPlatformServerName())))
->appendChild( ->appendChild(
id(new PhabricatorAuthAccountView()) id(new PhabricatorAuthAccountView())
->setUser($viewer) ->setUser($viewer)

View file

@ -56,8 +56,8 @@ final class PhabricatorAuthLinkController
pht('Account Already Linked'), pht('Account Already Linked'),
array( array(
pht( pht(
'Your Phabricator account is already linked to an external '. 'Your account is already linked to an external account for '.
'account for this provider.'), 'this provider.'),
)); ));
} }
break; break;

View file

@ -86,8 +86,7 @@ EOREMARKUP
->setDescription( ->setDescription(
pht( pht(
'If you have multiple %s environments (like a '. 'If you have multiple %s environments (like a '.
'development/staging environment for working on testing '. 'development/staging environment and a production environment), '.
'Phabricator, and a production environment for deploying it), '.
'set the production environment URI here so that emails and other '. 'set the production environment URI here so that emails and other '.
'durable URIs will always generate with links pointing at the '. 'durable URIs will always generate with links pointing at the '.
'production environment. If unset, defaults to `%s`. Most '. 'production environment. If unset, defaults to `%s`. Most '.

View file

@ -119,7 +119,9 @@ final class PhabricatorMetaMTAMailViewController
if ($mail->getFrom()) { if ($mail->getFrom()) {
$from_str = $viewer->renderHandle($mail->getFrom()); $from_str = $viewer->renderHandle($mail->getFrom());
} else { } else {
$from_str = pht('Sent by Phabricator'); $from_str = pht(
'Sent by %s',
PlatformSymbols::getPlatformServerName());
} }
$properties->addProperty( $properties->addProperty(
pht('From'), pht('From'),

View file

@ -60,7 +60,9 @@ final class PhabricatorPeopleWelcomeMailEngine
$message = array(); $message = array();
$message[] = pht('Welcome to Phabricator!'); $message[] = pht(
'Welcome to %s!',
PlatformSymbols::getPlatformServerName());
$message[] = pht( $message[] = pht(
'%s (%s) has created an account for you.', '%s (%s) has created an account for you.',
@ -129,7 +131,9 @@ final class PhabricatorPeopleWelcomeMailEngine
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business'); $is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
if (!$is_serious) { if (!$is_serious) {
return pht("Love,\nPhabricator"); return pht(
"Love,\n%s",
PlatformSymbols::getPlatformServerName());
} }
return null; return null;