Small style fixes

This commit is contained in:
Caleb J. Gardner
2025-09-05 03:39:12 -05:00
parent 243fa03af0
commit 338eb84469
3 changed files with 13 additions and 13 deletions
+3 -3
View File
@@ -18,7 +18,7 @@ var robotEmbed embed.FS
// A simple backend that handles user authentication, user count, and crash reports.
type Backend struct {
userTable Table[User]
keyTable Table[ApiKey]
keyTable Table[APIKey]
m *http.ServeMux
apps map[string]App
managementKeyID string
@@ -29,7 +29,7 @@ type Backend struct {
}
// Create a new Backend with the given apps. keyTable must be specified.
func NewBackend(keyTable Table[ApiKey], apps ...App) (*Backend, error) {
func NewBackend(keyTable Table[APIKey], apps ...App) (*Backend, error) {
b := &Backend{
keyTable: keyTable,
m: &http.ServeMux{},
@@ -143,7 +143,7 @@ func (b *Backend) HandleFunc(pattern string, h http.HandlerFunc) {
}
// Try to get the App associated with the given ApiKey. Returns nil if not found.
func (b *Backend) GetApp(a *ApiKey) App {
func (b *Backend) GetApp(a *APIKey) App {
return b.apps[a.AppID]
}