mirror of https://github.com/laurent22/joplin.git
Review comments - throw an error if callback url is not valid
parent
2b6b4dd916
commit
ee46978389
|
@ -22,7 +22,7 @@ export interface CallbackUrlInfo {
|
|||
}
|
||||
|
||||
export function parseUrl(s: string): CallbackUrlInfo {
|
||||
if (!s.startsWith('joplin://')) return null;
|
||||
if (!isCallbackUrl(s)) throw new Error(`Invalid callback url ${s}`);
|
||||
const url = new URL(s);
|
||||
|
||||
const params: Record<string, string> = {};
|
||||
|
|
Loading…
Reference in New Issue