aboutsummaryrefslogtreecommitdiffstats
path: root/commands
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2020-02-29 17:26:33 +0100
committerGitHub <noreply@github.com>2020-02-29 17:26:33 +0100
commit0b559bacd51cc78235abc89b4767b459cc0e4cfa (patch)
tree541b255e5044e476605679eb3b613b68b50c0049 /commands
parent140eae09c2311d2509e42376f1288da331705632 (diff)
parenta90954ae1a1b4d01d9695e45feb979c40ca42c9e (diff)
downloadgit-bug-0b559bacd51cc78235abc89b4767b459cc0e4cfa.tar.gz
Merge pull request #344 from MichaelMure/github-lowercase-login
github: fix matching cred/identity with badly cased login
Diffstat (limited to 'commands')
-rw-r--r--commands/bridge_auth_addtoken.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/commands/bridge_auth_addtoken.go b/commands/bridge_auth_addtoken.go
index 338b170e..8eda28ac 100644
--- a/commands/bridge_auth_addtoken.go
+++ b/commands/bridge_auth_addtoken.go
@@ -24,6 +24,12 @@ var (
)
func runBridgeTokenAdd(cmd *cobra.Command, args []string) error {
+ // Note: as bridgeAuthAddTokenLogin is not checked against the remote bug-tracker,
+ // it's possible to register a credential with an incorrect login (including bad case).
+ // The consequence is that it will not get picked later by the bridge. I find that
+ // checking it would require a cumbersome UX (need to provide a base URL for some bridges, ...)
+ // so it's probably not worth it, unless we refactor that entirely.
+
if bridgeAuthAddTokenTarget == "" {
return fmt.Errorf("flag --target is required")
}