summaryrefslogtreecommitdiff
path: root/pkg/backend/webapi.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/backend/webapi.go')
-rw-r--r--pkg/backend/webapi.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/pkg/backend/webapi.go b/pkg/backend/webapi.go
index a19d933..3e4efd3 100644
--- a/pkg/backend/webapi.go
+++ b/pkg/backend/webapi.go
@@ -64,12 +64,11 @@ func webGatewaySet(w http.ResponseWriter, r *http.Request) {
}
func webGatewayList(w http.ResponseWriter, r *http.Request) {
- gws, err := ctx.bm.ListGatewaysByCity(ctx.Provider)
+ locationJson, err := json.Marshal(ctx.bm.ListLocationFullness("openvpn"))
if err != nil {
- fmt.Fprintf(w, "ListGatewaysByCity() err: %v", err)
+ fmt.Fprintf(w, "Error converting json: %v", err)
}
- gwJson, _ := json.Marshal(gws)
- fmt.Fprintf(w, string(gwJson))
+ fmt.Fprintf(w, string(locationJson))
}
// TODO