🐛 Fixed empty application name on authorize page

This commit is contained in:
Maxim Lebedev 2023-08-05 09:33:53 +06:00
parent d02a35c897
commit 83b3b21c6b
Signed by: toby3d
GPG key ID: 1F14E25B7C119FC5
6 changed files with 15 additions and 8 deletions

View file

@ -13,7 +13,7 @@
"type": "string",
"underlyingType": "string",
"argNum": 1,
"expr": "p.Client.GetName()"
"expr": "name"
}
],
"fuzzy": true
@ -46,6 +46,13 @@
"translatorComment": "The name of the button to continue the application authorization process",
"fuzzy": true
},
{
"id": "version",
"message": "version",
"translation": "version",
"translatorComment": "Copied from source.",
"fuzzy": true
},
{
"id": "Error",
"message": "Error",

View file

@ -13,7 +13,7 @@
"type": "string",
"underlyingType": "string",
"argNum": 1,
"expr": "p.Client.GetName()"
"expr": "name"
}
],
"fuzzy": true

View file

@ -13,7 +13,7 @@
"type": "string",
"underlyingType": "string",
"argNum": 1,
"expr": "p.Client.GetName()"
"expr": "name"
}
]
},

View file

@ -13,7 +13,7 @@
"type": "string",
"underlyingType": "string",
"argNum": 1,
"expr": "p.Client.GetName()"
"expr": "name"
}
]
},

View file

@ -17,8 +17,8 @@
} %}
{% func (p *AuthorizePage) Title() %}
{% if p.Client.GetName() == "" %}
{%= p.T("Authorize %s", p.Client.GetName()) %}
{% if name := p.Client.GetName(); name != "" %}
{%= p.T("Authorize %s", name) %}
{% else %}
{%= p.T("Authorize application") %}
{% endif %}

View file

@ -43,12 +43,12 @@ func (p *AuthorizePage) StreamTitle(qw422016 *qt422016.Writer) {
qw422016.N().S(`
`)
//line web/authorize.qtpl:20
if p.Client.GetName() == "" {
if name := p.Client.GetName(); name != "" {
//line web/authorize.qtpl:20
qw422016.N().S(`
`)
//line web/authorize.qtpl:21
p.StreamT(qw422016, "Authorize %s", p.Client.GetName())
p.StreamT(qw422016, "Authorize %s", name)
//line web/authorize.qtpl:21
qw422016.N().S(`
`)