db, sqliteconfig: consolidate query and config helpers

This commit is contained in:
Kristoffer Dalby
2026-06-16 08:45:11 +00:00
parent b56326427c
commit 55b9e3cfda
13 changed files with 232 additions and 325 deletions
+2 -2
View File
@@ -247,7 +247,7 @@ func NewState(cfg *types.Config) (*State, error) {
node.IsOnline = new(false)
}
users, err := db.ListUsers()
users, err := db.ListUsers(nil)
if err != nil {
return nil, fmt.Errorf("loading users: %w", err)
}
@@ -508,7 +508,7 @@ func (s *State) ListUsersWithFilter(filter *types.User) ([]types.User, error) {
// ListAllUsers retrieves all users in the system.
func (s *State) ListAllUsers() ([]types.User, error) {
return s.db.ListUsers()
return s.db.ListUsers(nil)
}
// persistNodeRowToDB writes the node's database row, re-reading the