Password manager references removed strings (saveLoginText, saveLoginTextNoUsername)

RESOLVED FIXED in mozilla9

Status

()

Toolkit
Password Manager
RESOLVED FIXED
7 years ago
6 years ago

People

(Reporter: standard8, Assigned: felix)

Tracking

({regression})

unspecified
mozilla9
regression
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

7 years ago
I was just looking at some l10n stuff for Thunderbird and noticed the following in mozilla-central:

http://hg.mozilla.org/mozilla-central/annotate/acb48b922e91/toolkit/components/passwordmgr/src/nsLoginManagerPrompter.js#l970

        if (aLogin.username) {
            var displayUser = this._sanitizeUsername(aLogin.username);
            dialogText = this._getLocalizedString(
                                 "saveLoginText",
                                 [brandShortName, displayUser, displayHost]);
        } else {
            dialogText = this._getLocalizedString(
                                 "saveLoginTextNoUsername",
                                 [brandShortName, displayHost]);
        }
Both those strings are no longer defined in l10n land. I'm not sure if this code will really be hit (probably not frequently) but I suspect it isn't going to give good results if it does.

This is a regression from bug 594572.
Fuuuuuu... :/

Oh, but we can't actually hit this in Firefox-land because this code only gets invoked if it can't figure out how to get at a doorhanger or notification bar. [Well, ok, we probably could if an addond created a non-<browser> thing in which a user could browser and submit forms, but that's rather edge-caseish.]
(Assignee)

Updated

6 years ago
Assignee: nobody → ffung
(Assignee)

Comment 2

6 years ago
Created attachment 558993 [details] [diff] [review]
Reference Correct Strings in Password Manager

Restored the changes produced by the patch to https://bugzilla.mozilla.org/show_bug.cgi?id=594572
Attachment #558993 - Flags: review?(margaret.leibovic)
Attachment #558993 - Flags: review?(dolske)
Comment on attachment 558993 [details] [diff] [review]
Reference Correct Strings in Password Manager

Review of attachment 558993 [details] [diff] [review]:
-----------------------------------------------------------------

I went through the other strings changed in bug 594572...

2 other strings -- in _showChangeLoginDialog() -- are also broken. (passwordChangeText, passwordChangeTextNoUser).

Let's go ahead and fix those too.

::: toolkit/components/passwordmgr/nsLoginManagerPrompter.js
@@ -956,5 @@
>              (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_1) +
>              (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_2);
>  
> -        var brandShortName =
> -                this._brandBundle.GetStringFromName("brandShortName");

This was the only use of ._brandBundle, so go ahead and delete that getter (line ~268).
Attachment #558993 - Flags: review?(margaret.leibovic)
Attachment #558993 - Flags: review?(dolske)
Attachment #558993 - Flags: review-
(Assignee)

Comment 4

6 years ago
Created attachment 559250 [details] [diff] [review]
Reference Correct Strings in Password Manager

Addressed above comments
Attachment #558993 - Attachment is obsolete: true
Attachment #559250 - Flags: review?(margaret.leibovic)
Attachment #559250 - Flags: review?(dolske)
Attachment #559250 - Flags: review?(margaret.leibovic)
Attachment #559250 - Flags: review?(dolske)
Attachment #559250 - Flags: review+

Comment 5

6 years ago
https://hg.mozilla.org/integration/fx-team/rev/0a36d58f2b4f
Whiteboard: [fixed-in-fx-team]

Comment 6

6 years ago
https://hg.mozilla.org/mozilla-central/rev/0a36d58f2b4f
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → mozilla9
You need to log in before you can comment on or make changes to this bug.