diff --git a/chrome/content/zotero/zoteroPane.js b/chrome/content/zotero/zoteroPane.js index b44ceeb9f1..fc613172d6 100644 --- a/chrome/content/zotero/zoteroPane.js +++ b/chrome/content/zotero/zoteroPane.js @@ -5683,7 +5683,7 @@ var ZoteroPane = new function() var newName = Zotero.Attachments.getFileBaseNameFromItem(parentItem); let extRE = /\.[^\.]+$/; - let origFilename = file.split("/").pop(); + let origFilename = PathUtils.split(file).pop(); let ext = origFilename.match(extRE); if (ext) { newName = newName + ext[0];