1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-11-27 08:21:03 +02:00

Rename parseUrl -> parseCallbackUrl

This commit is contained in:
Roman 2021-08-14 23:18:58 +01:00
parent 90621a8417
commit 2386abea3e
2 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ import ShareService from '@joplin/lib/services/share/ShareService';
import { reg } from '@joplin/lib/registry';
import removeKeylessItems from '../ResizableLayout/utils/removeKeylessItems';
import { localSyncInfoFromState } from '@joplin/lib/services/synchronizer/syncInfoUtils';
import { parseUrl } from '@joplin/lib/ProtocolUtils';
import { parseCallbackUrl } from '@joplin/lib/ProtocolUtils';
import ElectronAppWrapper from '../../ElectronAppWrapper';
const { connect } = require('react-redux');
@ -202,7 +202,7 @@ class MainScreenComponent extends React.Component<Props, State> {
private openUrl(url: string) {
console.log(`openUrl ${url}`);
const { command, params } = parseUrl(url);
const { command, params } = parseCallbackUrl(url);
void CommandService.instance().execute(command, params.id);
}

View File

@ -21,7 +21,7 @@ export interface CallbackUrlInfo {
params: Record<string, string>;
}
export function parseUrl(s: string): CallbackUrlInfo {
export function parseCallbackUrl(s: string): CallbackUrlInfo {
if (!isCallbackUrl(s)) throw new Error(`Invalid callback url ${s}`);
const url = new URL(s);