mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 08:36:12 +01:00
feat: add translateKeys
This commit is contained in:
@@ -605,6 +605,9 @@
|
||||
warn('Translation failed: ' + err.stack);
|
||||
});
|
||||
},
|
||||
translateKeys: async function (keys, language, cb) {
|
||||
return await Promise.all(keys.map(key => adaptor.translate(key, language, cb)));
|
||||
},
|
||||
|
||||
/**
|
||||
* Add translations to the cache
|
||||
|
||||
Reference in New Issue
Block a user