diff options
| author | bndw <ben@bdw.to> | 2026-02-15 10:19:39 -0800 |
|---|---|---|
| committer | bndw <ben@bdw.to> | 2026-02-15 10:19:39 -0800 |
| commit | 16a38f97183e4cbaf95c510c85d61f5a45873f4b (patch) | |
| tree | 67042b77b77156e057c6fdd49207bfccc101aaaa /internal/auth | |
| parent | ae95a3fd20b5dc8c25ee947f5cc8e120a185b8bc (diff) | |
fix: add YAML tags to AuthOperationConfig
The AuthOperationConfig struct was missing YAML tags, causing
the config loader to not properly parse allowed_npubs from YAML.
This was causing TestNpubNormalization to fail with an index out
of range panic because AllowedNpubs was always empty.
Diffstat (limited to 'internal/auth')
| -rw-r--r-- | internal/auth/interceptor.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/auth/interceptor.go b/internal/auth/interceptor.go index 67450ce..2633adb 100644 --- a/internal/auth/interceptor.go +++ b/internal/auth/interceptor.go | |||
| @@ -26,8 +26,8 @@ type InterceptorOptions struct { | |||
| 26 | } | 26 | } |
| 27 | 27 | ||
| 28 | type AuthOperationConfig struct { | 28 | type AuthOperationConfig struct { |
| 29 | Enabled bool | 29 | Enabled bool `yaml:"enabled"` |
| 30 | AllowedNpubs []string | 30 | AllowedNpubs []string `yaml:"allowed_npubs"` |
| 31 | } | 31 | } |
| 32 | 32 | ||
| 33 | func DefaultInterceptorOptions() *InterceptorOptions { | 33 | func DefaultInterceptorOptions() *InterceptorOptions { |
