mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-16 13:48:41 -09:00
fix handling ssh link with empty user (#3521)
This commit is contained in:
parent
81ff38c8d9
commit
26846cd847
1 changed files with 1 additions and 1 deletions
|
|
@ -287,7 +287,7 @@ export function openSSH(url) {
|
||||||
type: UI_OPEN_SSH_URL,
|
type: UI_OPEN_SSH_URL,
|
||||||
effect() {
|
effect() {
|
||||||
let parsedUrl = parseUrl(url, true);
|
let parsedUrl = parseUrl(url, true);
|
||||||
let command = parsedUrl.protocol + ' ' + (parsedUrl.user || '') + '@' + parsedUrl.resource;
|
let command = parsedUrl.protocol + ' ' + (parsedUrl.user ? `${parsedUrl.user}@` : '') + parsedUrl.resource;
|
||||||
|
|
||||||
if (parsedUrl.port) command += ' -p ' + parsedUrl.port;
|
if (parsedUrl.port) command += ' -p ' + parsedUrl.port;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue