Skip to content

Commit

Permalink
Merge branch 'main' into webhook
Browse files Browse the repository at this point in the history
  • Loading branch information
lafriks authored Aug 3, 2022
2 parents 24dab3a + 87a7c37 commit 5ae9cc4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions modules/ssh/ssh.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ func sessionHandler(session ssh.Session) {
gitProtocol := ""
for _, env := range session.Environ() {
if strings.HasPrefix(env, "GIT_PROTOCOL=") {
// The value would be version=2, so using normal split doesn't work here.
gitProtocol = strings.SplitN(env, "=", 2)[1]
_, gitProtocol, _ = strings.Cut(env, "=")
break
}
}
Expand Down

0 comments on commit 5ae9cc4

Please sign in to comment.