You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-24 23:26:50 +02:00
Desktop: Fixed attaching local files that contain spaces in path
Ref: https://discourse.joplinapp.org/t/a-minor-bug-on-linking-to-local-files/13654
This commit is contained in:
@ -121,7 +121,6 @@ export function toFileProtocolPath(filePathEncode: string, os: string = null) {
|
||||
|
||||
filePathEncode = encodeURI(filePathEncode);
|
||||
filePathEncode = filePathEncode.replace(/\+/g, '%2B'); // escape '+' with unicode
|
||||
filePathEncode = filePathEncode.replace(/%20/g, '+'); // switch space (%20) with '+'. To comply with syntax used by joplin, see urldecode_(str) in MdToHtml.js
|
||||
return `file://${filePathEncode.replace(/\'/g, '%27')}`; // escape '(single quote) with unicode, to prevent crashing the html view
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user