From 19cfbb3f4de913f738a684aa2d445f6c34ef5aa0 Mon Sep 17 00:00:00 2001 From: icey-yu <1186114839@qq.com> Date: Wed, 12 Jun 2024 14:20:42 +0800 Subject: [PATCH] refactor:change standardized URL --- internal/push/offlinepush/fcm/push.go | 4 ++-- pkg/common/config/config.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/push/offlinepush/fcm/push.go b/internal/push/offlinepush/fcm/push.go index b1ccc88888..329cb6ae88 100644 --- a/internal/push/offlinepush/fcm/push.go +++ b/internal/push/offlinepush/fcm/push.go @@ -48,10 +48,10 @@ func NewClient(pushConf *config.Push, cache cache.ThirdCache, fcmConfigPath stri // with file path credentialsFilePath := filepath.Join(fcmConfigPath, pushConf.FCM.FilePath) opt = option.WithCredentialsFile(credentialsFilePath) - case len(pushConf.FCM.AuthUrl) != 0: + case len(pushConf.FCM.AuthURL) != 0: // with authentication URL client := httputil.NewHTTPClient(httputil.NewClientConfig()) - resp, err := client.Get(pushConf.FCM.AuthUrl) + resp, err := client.Get(pushConf.FCM.AuthURL) if err != nil { return nil, err } diff --git a/pkg/common/config/config.go b/pkg/common/config/config.go index 5cd6a1abd3..6260dc00f5 100644 --- a/pkg/common/config/config.go +++ b/pkg/common/config/config.go @@ -203,7 +203,7 @@ type Push struct { } `mapstructure:"geTui"` FCM struct { FilePath string `mapstructure:"filePath"` - AuthUrl string `mapstructure:"authURL"` + AuthURL string `mapstructure:"authURL"` } `mapstructure:"fcm"` JPNS struct { AppKey string `mapstructure:"appKey"`