1
0
mirror of https://github.com/haiwen/seafile-server.git synced 2025-08-15 13:34:45 +00:00

Fix error for notification server

This commit is contained in:
杨赫然 2024-12-18 16:42:01 +08:00
parent 3fcbc9dc04
commit 202dd20be0

View File

@ -10,8 +10,8 @@ import (
"os" "os"
"os/signal" "os/signal"
"path/filepath" "path/filepath"
"strings"
"strconv" "strconv"
"strings"
"syscall" "syscall"
"time" "time"
@ -46,7 +46,7 @@ func init() {
} }
func loadNotifConfig() { func loadNotifConfig() {
host := os.Getenv("NOTIFICATION_SERVER_HOST") host = os.Getenv("NOTIFICATION_SERVER_HOST")
if host == "" { if host == "" {
host = "0.0.0.0" host = "0.0.0.0"
} }
@ -55,7 +55,7 @@ func loadNotifConfig() {
if os.Getenv("NOTIFICATION_SERVER_PORT") != "" { if os.Getenv("NOTIFICATION_SERVER_PORT") != "" {
i, err := strconv.Atoi(os.Getenv("NOTIFICATION_SERVER_PORT")) i, err := strconv.Atoi(os.Getenv("NOTIFICATION_SERVER_PORT"))
if err == nil { if err == nil {
port = i port = uint32(i)
} }
} }