Closed Bug 1191163 Opened 9 years ago Closed 9 years ago

Remove innerHTML from translations in FTU

Categories

(Firefox OS Graveyard :: Gaia::First Time Experience, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: stas, Assigned: stas)

References

Details

Attachments

(1 file)

46 bytes, text/x-github-pull-request
sfoster
: review+
flod
: feedback+
Details | Review
innerHTML in translations is unsafe and we're phasing it away after a long deprecation period.
Attached file Pull request
There's only one occurrence of innerHTML in FTU's translations: let's remove it.  Flod, Sam -- can you both take a look please?
Assignee: nobody → stas
Status: NEW → ASSIGNED
Attachment #8643438 - Flags: review?(sfoster)
Attachment #8643438 - Flags: feedback?(francesco.lodolo)
Comment on attachment 8643438 [details] [review]
Pull request

String-wise it's OK, we'll pick up the string as a new ID.

Code-wise, the only reference I find is a mozL10n.setAttributes, which should keep working as before.
https://github.com/mozilla-b2g/gaia/blob/75071a1117605a7ac79c51025caf6ffcfc4dfa95/apps/ftu/js/ui.js#L507-L510
Attachment #8643438 - Flags: feedback?(francesco.lodolo) → feedback+
Comment on attachment 8643438 [details] [review]
Pull request

Looks good. Feel free to also remove the default text from index.html - I think the idea is to eventually get of rid of that too?
Attachment #8643438 - Flags: review?(sfoster) → review+
Thanks!  Merged in https://github.com/mozilla-b2g/gaia/commit/2ec24f11a5e82aa25e5c1b4045da4838151682bd.  I also removed the en-US text from index.html, as you suggested.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: