Skip to content

Commit

Permalink
fix: πŸ› fix getPrefix for windows
Browse files Browse the repository at this point in the history
βœ… Closes: 28
  • Loading branch information
Nick Reese committed Oct 3, 2020
1 parent de27092 commit 546be36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/images/utils/getPrefix.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const getPrefix = (rel, publicPrefix) => {
const fileWithoutExt = rel.split('.')[0];
return fileWithoutExt + publicPrefix.split(fileWithoutExt).pop();
return fileWithoutExt + publicPrefix.replace(/\\/g, '/').split(fileWithoutExt).pop();
};

module.exports = getPrefix;
Expand Down

0 comments on commit 546be36

Please sign in to comment.