mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-27 00:56:13 +01:00
feat: use assetBaseUrl instead of hardcoding
This commit is contained in:
@@ -197,7 +197,7 @@ module.exports = function (middleware) {
|
|||||||
|
|
||||||
if (languageCodes.includes(userLang) && languages.timeagoCodes.includes(timeagoCode)) {
|
if (languageCodes.includes(userLang) && languages.timeagoCodes.includes(timeagoCode)) {
|
||||||
const pathToLocaleFile = '/vendor/jquery/timeago/locales/jquery.timeago.' + timeagoCode + '.js';
|
const pathToLocaleFile = '/vendor/jquery/timeago/locales/jquery.timeago.' + timeagoCode + '.js';
|
||||||
return nconf.get('relative_path') + '/assets' + pathToLocaleFile;
|
return res.locals.config.assetBaseUrl + pathToLocaleFile;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
})(),
|
})(),
|
||||||
|
|||||||
Reference in New Issue
Block a user