diff options
author | Michael Muré <batolettre@gmail.com> | 2019-09-02 11:34:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-02 11:34:47 +0200 |
commit | 16af70894c0348ec90dfee69274f7d44ef2eb079 (patch) | |
tree | 5018a7356afa8ade6a69eb8767aa7a3439aa01da /bridge/launchpad/config.go | |
parent | c7792a5d1279a92c8d0caf67a0cf688cc9e32e09 (diff) | |
parent | f3d8da10750d58fce482042cff87455a1e6f36e0 (diff) | |
download | git-bug-16af70894c0348ec90dfee69274f7d44ef2eb079.tar.gz |
Merge pull request #200 from MichaelMure/bridge-token-stdin
bridge: support --token-stdin
Diffstat (limited to 'bridge/launchpad/config.go')
-rw-r--r-- | bridge/launchpad/config.go | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/bridge/launchpad/config.go b/bridge/launchpad/config.go index 1d6c8aba..6669d0fa 100644 --- a/bridge/launchpad/config.go +++ b/bridge/launchpad/config.go @@ -22,7 +22,7 @@ const ( defaultTimeout = 60 * time.Second ) -func (*Launchpad) Configure(repo repository.RepoCommon, params core.BridgeParams) (core.Configuration, error) { +func (l *Launchpad) Configure(repo repository.RepoCommon, params core.BridgeParams) (core.Configuration, error) { if params.Token != "" { fmt.Println("warning: --token is ineffective for a Launchpad bridge") } @@ -63,6 +63,12 @@ func (*Launchpad) Configure(repo repository.RepoCommon, params core.BridgeParams conf[keyProject] = project conf[core.KeyTarget] = target + + err = l.ValidateConfig(conf) + if err != nil { + return nil, err + } + return conf, nil } |