log bing err

This commit is contained in:
Sakurasan
2024-06-04 01:04:06 +08:00
parent afbc8e008b
commit b101da7677

View File

@@ -11,6 +11,7 @@ package search
import ( import (
"fmt" "fmt"
"io" "io"
"log"
"net/http" "net/http"
"net/url" "net/url"
"os" "os"
@@ -27,6 +28,8 @@ var subscriptionKey string
func init() { func init() {
if os.Getenv("bing") != "" { if os.Getenv("bing") != "" {
subscriptionKey = os.Getenv("bing") subscriptionKey = os.Getenv("bing")
} else {
log.Println("bing key not found")
} }
} }