fix: check correct default during template push from stdin (#15293)

I used the wrong default in #14643 - not sure how or why I didn't catch
that..
This commit is contained in:
Ethan
2024-10-31 02:05:10 +11:00
committed by GitHub
parent 144d3f3e3d
commit 371a2e12ab

View File

@ -282,7 +282,7 @@ func (pf *templateUploadFlags) stdin(inv *serpent.Invocation) (out bool) {
}
}()
// We let the directory override our isTTY check
return pf.directory == "-" || (!isTTYIn(inv) && pf.directory == "")
return pf.directory == "-" || (!isTTYIn(inv) && pf.directory == ".")
}
func (pf *templateUploadFlags) upload(inv *serpent.Invocation, client *codersdk.Client) (*codersdk.UploadResponse, error) {