Skip to content

Commit

Permalink
Rename jsonp files to js so they can be accessed by extensions kiwix#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Jaifroid authored Sep 10, 2023
1 parent 47cd543 commit 33a9d56
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 4 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions service-worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ const precacheFiles = [
'.', // This caches the redirect to www/index.html, in case a user launches the app from its root directory
'manifest.json',
'service-worker.js',
'i18n/en.jsonp',
'i18n/es.jsonp',
'i18n/fr.jsonp',
'i18n/en.jsonp.js',
'i18n/es.jsonp.js',
'i18n/fr.jsonp.js',
'www/css/app.css',
'www/css/kiwixJS_invert.css',
'www/css/kiwixJS_mwInvert.css',
Expand Down
2 changes: 1 addition & 1 deletion www/js/lib/translateUI.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ function loadTranslationStrings (langCode) {
if (!/^[a-zA-Z]{2,4}$/.test(langCode)) {
return Promise.reject(new Error('Invalid language code: ' + langCode));
}
return util.getJSONPObject('../i18n/' + langCode + '.jsonp').then(function (translations) {
return util.getJSONPObject('../i18n/' + langCode + '.jsonp.js').then(function (translations) {
currentLanguage = translations[langCode]['translation'];
// i18next.init({
// lng: langCode, // if you're using a language detector, do not define the lng option
Expand Down

0 comments on commit 33a9d56

Please sign in to comment.