mirror of
https://github.com/laurent22/joplin.git
synced 2026-06-18 20:16:34 +02:00
Review comments - escape vars in url
This commit is contained in:
1 parent
ecf718005d
commit
f0361bf80d
1 file changed
+3
-3
@@ -3,15 +3,15 @@ export function isCallbackUrl(s: string) {
|
||||
}
|
||||
|
||||
export function getNoteUrl(noteId: string) {
|
||||
return `joplin://x-callback-url/openNote?id=${noteId}`;
|
||||
return `joplin://x-callback-url/openNote?id=${encodeURIComponent(noteId)}`;
|
||||
}
|
||||
|
||||
export function getFolderUrl(folderId: string) {
|
||||
return `joplin://x-callback-url/openFolder?id=${folderId}`;
|
||||
return `joplin://x-callback-url/openFolder?id=${encodeURIComponent(folderId)}`;
|
||||
}
|
||||
|
||||
export function getTagUrl(tagId: string) {
|
||||
return `joplin://x-callback-url/openTag?id=${tagId}`;
|
||||
return `joplin://x-callback-url/openTag?id=${encodeURIComponent(tagId)}`;
|
||||
}
|
||||
|
||||
export type Command = 'openNote' | 'openFolder' | 'openTag';
|
||||
|
||||
Reference in new issue
Block a user