mirror of
https://github.com/actions/checkout.git
synced 2024-04-27 16:57:09 +08:00
Update src/url-helper.ts
Co-authored-by: Josh Gross <joshmgross@github.com>
This commit is contained in:
parent
a65c1f84e9
commit
e0908c08dc
@ -12,7 +12,7 @@ export function getFetchUrl(settings: IGitSourceSettings): string {
|
||||
const encodedOwner = encodeURIComponent(settings.repositoryOwner)
|
||||
const encodedName = encodeURIComponent(settings.repositoryName)
|
||||
if (settings.sshKey) {
|
||||
let user = settings.sshUser.length > 0 ? settings.sshUser : 'git'
|
||||
const user = settings.sshUser.length > 0 ? settings.sshUser : 'git'
|
||||
return `${user}@${serviceUrl.hostname}:${encodedOwner}/${encodedName}.git`
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user