Fix OAuth verifier display page title and msgs for i18n
This commit is contained in:
parent
5d56d9bb69
commit
b3cd558fe7
@ -612,20 +612,37 @@ class ApiOauthAuthorizeAction extends Action
|
|||||||
*/
|
*/
|
||||||
function showAuthorized()
|
function showAuthorized()
|
||||||
{
|
{
|
||||||
|
$title = null;
|
||||||
|
$msg = null;
|
||||||
|
|
||||||
|
if ($this->app->name == 'anonymous') {
|
||||||
|
|
||||||
|
$title =
|
||||||
|
// TRANS: Title of the page notifying the user that an anonymous client application was successfully authorized to access the user's account with OAuth.
|
||||||
|
_('You have successfully authorized the application');
|
||||||
|
|
||||||
|
$msg =
|
||||||
|
// TRANS: Message notifying the user that an anonymous client application was successfully authorized to access the user's account with OAuth.
|
||||||
|
_('Please return to the application and enter the following security code to complete the process.');
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
$title = sprintf(
|
$title = sprintf(
|
||||||
// TRANS: Header of user notification after authorising an application access to a profile.
|
// TRANS: Title of the page notifying the user that the client application was successfully authorized to access the user's account with OAuth.
|
||||||
// TRANS: %s is the authorised application name.
|
// TRANS: %s is the authorised application name.
|
||||||
_('You have successfully authorized %s.'),
|
_('You have successfully authorized %s'),
|
||||||
($this->app->name == 'anonymous') ? 'the application' : $this->app->name
|
$this->app->name
|
||||||
);
|
);
|
||||||
|
|
||||||
$msg = sprintf(
|
$msg = sprintf(
|
||||||
// TRANS: Uer notification after authorising an application access to a profile.
|
// TRANS: Message notifying the user that the client application was successfully authorized to access the user's account with OAuth.
|
||||||
// TRANS: %s is the authorised application name.
|
// TRANS: %s is the authorised application name.
|
||||||
_('Please return to %s and enter the following security code to complete the process.'),
|
_('Please return to %s and enter the following security code to complete the process.'),
|
||||||
($this->app->name == 'anonymous') ? 'the application' : $this->app->name
|
$this->app->name
|
||||||
);
|
);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
if ($this->reqToken->verified_callback == 'oob') {
|
if ($this->reqToken->verified_callback == 'oob') {
|
||||||
$pin = new ApiOauthPinAction(
|
$pin = new ApiOauthPinAction(
|
||||||
$title,
|
$title,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user