From 3631eb6db413607eaf68825200b0c5c1a3195fea Mon Sep 17 00:00:00 2001 From: Mark Laing Date: Mon, 24 Jun 2024 17:48:41 +0100 Subject: [PATCH] *: Runs `gofmt -w -s ./`. This is required for static analysis to pass. Signed-off-by: Mark Laing --- client/lxd_events.go | 2 +- lxd-agent/devlxd.go | 2 +- lxd/api.go | 2 +- lxd/cluster/migrate.go | 2 +- lxd/events/devlxdEvents.go | 2 +- lxd/events/events.go | 2 +- lxd/instance_delete.go | 2 +- lxd/instance_get.go | 2 +- lxd/storage_volumes.go | 4 ++-- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/client/lxd_events.go b/client/lxd_events.go index e9e2e6d4c041..34fca93a597d 100644 --- a/client/lxd_events.go +++ b/client/lxd_events.go @@ -6,9 +6,9 @@ import ( "fmt" "time" - "github.com/gorilla/websocket" "github.com/canonical/lxd/shared" "github.com/canonical/lxd/shared/api" + "github.com/gorilla/websocket" ) // Event handling functions diff --git a/lxd-agent/devlxd.go b/lxd-agent/devlxd.go index 103c3747c328..2b0fb5ebe108 100644 --- a/lxd-agent/devlxd.go +++ b/lxd-agent/devlxd.go @@ -10,12 +10,12 @@ import ( "path/filepath" "strings" - "github.com/gorilla/mux" "github.com/canonical/lxd/lxd/daemon" "github.com/canonical/lxd/lxd/util" "github.com/canonical/lxd/shared" "github.com/canonical/lxd/shared/logger" "github.com/canonical/lxd/shared/version" + "github.com/gorilla/mux" ) // DevLxdServer creates an http.Server capable of handling requests against the diff --git a/lxd/api.go b/lxd/api.go index d0392f7c492b..d9482d1a2775 100644 --- a/lxd/api.go +++ b/lxd/api.go @@ -7,7 +7,6 @@ import ( log "gopkg.in/inconshreveable/log15.v2" - "github.com/gorilla/mux" "github.com/canonical/lxd/lxd/cluster" "github.com/canonical/lxd/lxd/cluster/request" "github.com/canonical/lxd/lxd/db" @@ -15,6 +14,7 @@ import ( lxdRequest "github.com/canonical/lxd/lxd/request" "github.com/canonical/lxd/lxd/response" "github.com/canonical/lxd/shared/logger" + "github.com/gorilla/mux" ) // swagger:operation GET / server api_get diff --git a/lxd/cluster/migrate.go b/lxd/cluster/migrate.go index d48409b89e28..c0ce9590070a 100644 --- a/lxd/cluster/migrate.go +++ b/lxd/cluster/migrate.go @@ -8,9 +8,9 @@ import ( "path/filepath" "strconv" - "github.com/hashicorp/go-msgpack/codec" "github.com/canonical/lxd/lxd/cluster/raft" "github.com/canonical/lxd/shared" + "github.com/hashicorp/go-msgpack/codec" bolt "go.etcd.io/bbolt" ) diff --git a/lxd/events/devlxdEvents.go b/lxd/events/devlxdEvents.go index 6d72be8daf17..08c92e8de509 100644 --- a/lxd/events/devlxdEvents.go +++ b/lxd/events/devlxdEvents.go @@ -8,9 +8,9 @@ import ( "github.com/pborman/uuid" - "github.com/gorilla/websocket" "github.com/canonical/lxd/shared" "github.com/canonical/lxd/shared/api" + "github.com/gorilla/websocket" ) // DevLXDServer represents an instance of an devlxd event server. diff --git a/lxd/events/events.go b/lxd/events/events.go index 455b61b293d1..dfa78ece8430 100644 --- a/lxd/events/events.go +++ b/lxd/events/events.go @@ -8,10 +8,10 @@ import ( "github.com/pborman/uuid" - "github.com/gorilla/websocket" "github.com/canonical/lxd/shared" "github.com/canonical/lxd/shared/api" "github.com/canonical/lxd/shared/logger" + "github.com/gorilla/websocket" ) // EventSource indicates the source of an event. diff --git a/lxd/instance_delete.go b/lxd/instance_delete.go index af63ee1a148a..a95b496959c3 100644 --- a/lxd/instance_delete.go +++ b/lxd/instance_delete.go @@ -4,12 +4,12 @@ import ( "fmt" "net/http" - "github.com/gorilla/mux" "github.com/canonical/lxd/lxd/db" "github.com/canonical/lxd/lxd/instance" "github.com/canonical/lxd/lxd/instance/instancetype" "github.com/canonical/lxd/lxd/operations" "github.com/canonical/lxd/lxd/response" + "github.com/gorilla/mux" ) // swagger:operation DELETE /1.0/instances/{name} instances instance_delete diff --git a/lxd/instance_get.go b/lxd/instance_get.go index 1ffe9e95c559..dbfafb3c656a 100644 --- a/lxd/instance_get.go +++ b/lxd/instance_get.go @@ -3,9 +3,9 @@ package main import ( "net/http" - "github.com/gorilla/mux" "github.com/canonical/lxd/lxd/instance" "github.com/canonical/lxd/lxd/response" + "github.com/gorilla/mux" ) // swagger:operation GET /1.0/instances/{name} instances instance_get diff --git a/lxd/storage_volumes.go b/lxd/storage_volumes.go index e3cfa2cb0930..bd32c9941cc5 100644 --- a/lxd/storage_volumes.go +++ b/lxd/storage_volumes.go @@ -11,8 +11,6 @@ import ( log "gopkg.in/inconshreveable/log15.v2" - "github.com/gorilla/mux" - "github.com/gorilla/websocket" "github.com/canonical/lxd/lxd/db" "github.com/canonical/lxd/lxd/instance" "github.com/canonical/lxd/lxd/operations" @@ -26,6 +24,8 @@ import ( "github.com/canonical/lxd/shared/api" "github.com/canonical/lxd/shared/logger" "github.com/canonical/lxd/shared/version" + "github.com/gorilla/mux" + "github.com/gorilla/websocket" ) var storagePoolVolumesCmd = APIEndpoint{