From 416055e02b74f640ab6030deaa9f7767221a49cd Mon Sep 17 00:00:00 2001 From: sanine-a Date: Mon, 1 May 2023 14:07:39 -0500 Subject: add additional configuration functions for users and endpoints --- db/db.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'db/db.go') diff --git a/db/db.go b/db/db.go index d9faff3..a9a9a2e 100644 --- a/db/db.go +++ b/db/db.go @@ -41,6 +41,7 @@ type Model interface { GetSchemaVersion() (int, error) CreateUser(username, password string) (User, error) + SetPassword(user User, password string) error AuthenticateUser(username, password string) (User, error) GetById(id string) (User, error) AllUsers() ([]User, error) @@ -53,6 +54,8 @@ type Model interface { CreateEndpoint(name, path, address string) (Endpoint, error) DeleteEndpoint(endpoint Endpoint) error + SetEndpointPath(endpoint Endpoint, path string) error + SetEndpointAddress(endpoint Endpoint, address string) error GetEndpointByName(name string) (Endpoint, error) GetEndpointByPath(path string) (Endpoint, error) GetEndpointByAddress(address string) (Endpoint, error) -- cgit v1.2.1