Skip to content

Commit

Permalink
fixed testing empty branch name
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Horton <[email protected]>
  • Loading branch information
madpah committed Dec 10, 2024
1 parent aab4f8f commit 8690a51
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions scm/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,9 @@ func (a *Application) IsRepositoryUrlPermitted() bool {
}

func safeBranchName(in string) bool {
if strings.TrimSpace(in) == "" {
return false
}
return !INVALID_BRANCH_NAME.MatchString(in)
}

Expand Down

0 comments on commit 8690a51

Please sign in to comment.