Closed Bug 1764193 Opened 3 years ago Closed 3 years ago

LanguageDetector.jsm missing in Thunderbird

Categories

(Thunderbird :: Add-Ons: Extensions API, defect)

Thunderbird 91
defect

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1764698

People

(Reporter: buecher, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: intl)

cannot detect language of a string due to missing file.

Code used, from MDN:
let detectingLanguages = await browser.i18n.detectLanguage(
editor.text // string
);

Summary: add LanguageDetector.jsm to ESR91 → LanguageDetector.jsm missing in Thunderbird

@Magnus: How should we fix this? The test for i18n is disabled for Thunderbird, so I never knew about it:
https://searchfox.org/mozilla-central/source/toolkit/components/extensions/test/xpcshell/test_ext_i18n.js

Code living in toolkit is including code from browser, which breaks for us.

Should we clone the file or register a link to browser, so resource:///modules/translation/LanguageDetector.jsm works for us as well?

I looked around but did not find the mechanism to register resource:///modules/translation/* for us. I will need a push in the right direction, to be able to fix this. Thanks.

Flags: needinfo?(mkmelin+mozilla)

LanguageDetector.jsm is in the wrong place, it really should be in toolkit. The fix is to move LanguageDetector.jsm to toolkit.

Flags: needinfo?(mkmelin+mozilla)
See Also: → 1764698
Keywords: intl

The m-c bug is being fixed. Can I close this as a dupe?

Sounds good, thanks for fixing!!

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.