fleetmap-reports 1.0.240 → 1.0.241

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fleetmap-reports",
3
- "version": "1.0.240",
3
+ "version": "1.0.241",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
package/src/kms-report.js CHANGED
@@ -104,7 +104,7 @@ async function createKmsReport(from, to, userData, traccar) {
104
104
  }
105
105
 
106
106
  async function exportKmsReportToPDF(userData, reportData) {
107
- const lang = userData.user.attributes.lang
107
+ const lang = userData.user.attributes.lang || (navigator && navigator.language)
108
108
  const translations = messages[lang] ? messages[lang] : messages['en-GB']
109
109
  const kmsData = userData.byDriver ? reportData.drivers : reportData.devices
110
110