From 69a98f4b5bc59a41b5c6bf1221b310d0299ee715 Mon Sep 17 00:00:00 2001 From: Rhythm <35167328+kRhythm@users.noreply.github.com> Date: Wed, 5 Jan 2022 16:42:09 +0530 Subject: [PATCH] fmted stuff --- handlers/routes.go | 2 +- handlers/services.go | 2 +- types/services/struct.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/handlers/routes.go b/handlers/routes.go index 5f7e2a2d..d2eb1018 100644 --- a/handlers/routes.go +++ b/handlers/routes.go @@ -131,7 +131,7 @@ func Router() *mux.Router { // API SERVICE Routes api.Handle("/api/services", scoped(apiAllServicesHandler)).Methods("GET") - api.Handle("/api/services/status", authenticated(apiAllServicesStatusHandler,false)).Methods("GET") + api.Handle("/api/services/status", authenticated(apiAllServicesStatusHandler, false)).Methods("GET") api.Handle("/api/services", authenticated(apiCreateServiceHandler, false)).Methods("POST") api.Handle("/api/services/{id}", authenticatedV2(apiServiceHandler)).Methods("GET") api.Handle("/api/services/{id}/sub_services", scoped(apiAllSubServicesHandler)).Methods("GET") diff --git a/handlers/services.go b/handlers/services.go index 7186c5c1..2174edf2 100644 --- a/handlers/services.go +++ b/handlers/services.go @@ -551,7 +551,7 @@ func apiAllServicesHandler(r *http.Request) interface{} { return srvs } -func apiAllServicesStatusHandler(w http.ResponseWriter, r *http.Request){ +func apiAllServicesStatusHandler(w http.ResponseWriter, r *http.Request) { query := r.URL.Query() var t string if query.Get("time") != "" { diff --git a/types/services/struct.go b/types/services/struct.go index 0fdc649d..179a423b 100644 --- a/types/services/struct.go +++ b/types/services/struct.go @@ -14,7 +14,7 @@ import ( type ServiceWithDowntime struct { Service - Downtime *downtimes.Downtime `gorm:"-" json:"downtime" yaml:"-"` + Downtime *downtimes.Downtime `gorm:"-" json:"downtime" yaml:"-"` } // Service is the main struct for Services