From c1687baece2faf56687696c9a35ac495d0ccb633 Mon Sep 17 00:00:00 2001 From: Roland Bewick Date: Thu, 18 Jan 2024 21:13:41 +0700 Subject: [PATCH] chore: rename new service function --- main.go | 2 +- main_http.go | 2 +- main_wails.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/main.go b/main.go index 464aa1f2..db391d85 100644 --- a/main.go +++ b/main.go @@ -28,7 +28,7 @@ import ( ) // TODO: move to service.go -func CreateService(wg *sync.WaitGroup) *Service { +func NewService(wg *sync.WaitGroup) *Service { // Load config from environment variables / .env file godotenv.Load(".env") cfg := &Config{} diff --git a/main_http.go b/main_http.go index f4a9dcf4..2c2d25b4 100644 --- a/main_http.go +++ b/main_http.go @@ -24,7 +24,7 @@ func main() { var wg sync.WaitGroup wg.Add(1) - svc := CreateService(&wg) + svc := NewService(&wg) if svc.cfg.CookieSecret == "" { svc.Logger.Fatalf("required key COOKIE_SECRET missing value") diff --git a/main_wails.go b/main_wails.go index 25d8a164..8645e4ce 100644 --- a/main_wails.go +++ b/main_wails.go @@ -16,7 +16,7 @@ func main() { var wg sync.WaitGroup wg.Add(1) - svc := CreateService(&wg) + svc := NewService(&wg) go func() { app := NewApp(svc)