diff --git a/lib/file_transfer_agent/file_transfer_agent.js b/lib/file_transfer_agent/file_transfer_agent.js index d2b53aa1f..e9965d1d1 100644 --- a/lib/file_transfer_agent/file_transfer_agent.js +++ b/lib/file_transfer_agent/file_transfer_agent.js @@ -625,7 +625,7 @@ function FileTransferAgent(context) { const fileInfo = fs.statSync(matchingFileName); const currFileObj = {}; - currFileObj['srcFileName'] = matchingFileName.substring(matchingFileName.lastIndexOf('/') + 1); + currFileObj['srcFileName'] = path.basename(matchingFileName); currFileObj['srcFilePath'] = matchingFileName; currFileObj['srcFileSize'] = fileInfo.size; diff --git a/package.json b/package.json index 7667cc249..37635a771 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "fast-xml-parser": "^4.2.5", "fastest-levenshtein": "^1.0.16", "generic-pool": "^3.8.2", - "glob": "^9.0.0", + "glob": "^10.0.0", "https-proxy-agent": "^7.0.2", "jsonwebtoken": "^9.0.0", "mime-types": "^2.1.29",