鏡像自
https://github.com/quitesimpleorg/hs9001.git
synced 2024-11-22 04:07:52 +01:00
Search: Properly exit on error
This commit is contained in:
父節點
da945dce2d
當前提交
54697be895
1
main.go
1
main.go
@ -156,6 +156,7 @@ func main() {
|
|||||||
} else if cmd == "search" {
|
} else if cmd == "search" {
|
||||||
if argslen < 2 {
|
if argslen < 2 {
|
||||||
fmt.Fprint(os.Stderr, "Please provide the search query\n")
|
fmt.Fprint(os.Stderr, "Please provide the search query\n")
|
||||||
|
os.Exit(1)
|
||||||
}
|
}
|
||||||
q := strings.Join(args[1:], " ")
|
q := strings.Join(args[1:], " ")
|
||||||
search(conn, q)
|
search(conn, q)
|
||||||
|
載入中…
新增問題並參考
Block a user