ソースを参照

clean up CurrentUser global cfg logic

pull/36/head
Rob Loranger 4年前
コミット
024b7090ac
この署名に対応する既知のキーがデータベースに存在しません GPGキーID: D6F1633A4F0903B8
1個のファイルの変更2行の追加3行の削除
  1. +2
    -3
      config/user.go

+ 2
- 3
config/user.go ファイルの表示

@@ -159,11 +159,10 @@ func CurrentUser(c *cli.Context) (string, error) {
if err != nil {
return "", err
}
// only user global defaults when both are set and hosts match
// only use global defaults when both are set and no host flag
if globalCFG.Default.User != "" &&
globalCFG.Default.Host != "" &&
c.GlobalIsSet("host") &&
globalCFG.Default.Host == c.GlobalString("host") {
!c.GlobalIsSet("host") {
cfg = globalCFG
}
}


読み込み中…
キャンセル
保存