···1616 }
17171818 handler := &PrivacyPolicyHandler{
1919- Templates: templates,
2020- RegistryURL: "myregistry.example.com",
2121- CompanyName: "My Container Registry",
2222- Jurisdiction: "State of California, United States",
1919+ BaseUIHandler: BaseUIHandler{
2020+ Templates: templates,
2121+ RegistryURL: "myregistry.example.com",
2222+ CompanyName: "My Container Registry",
2323+ Jurisdiction: "State of California, United States",
2424+ },
2325 }
24262527 req := httptest.NewRequest("GET", "/privacy", nil)
···5759 }
58605961 handler := &TermsOfServiceHandler{
6060- Templates: templates,
6161- RegistryURL: "myregistry.example.com",
6262- CompanyName: "My Container Registry",
6363- Jurisdiction: "State of California, United States",
6262+ BaseUIHandler: BaseUIHandler{
6363+ Templates: templates,
6464+ RegistryURL: "myregistry.example.com",
6565+ CompanyName: "My Container Registry",
6666+ Jurisdiction: "State of California, United States",
6767+ },
6468 }
65696670 req := httptest.NewRequest("GET", "/terms", nil)
···106110107111 t.Run("privacy with defaults", func(t *testing.T) {
108112 handler := &PrivacyPolicyHandler{
109109- Templates: templates,
110110- RegistryURL: "atcr.io",
111111- CompanyName: "AT Container Registry",
112112- Jurisdiction: "State of Texas, United States",
113113+ BaseUIHandler: BaseUIHandler{
114114+ Templates: templates,
115115+ RegistryURL: "atcr.io",
116116+ CompanyName: "AT Container Registry",
117117+ Jurisdiction: "State of Texas, United States",
118118+ },
113119 }
114120115121 req := httptest.NewRequest("GET", "/privacy", nil)
···128134129135 t.Run("terms with defaults", func(t *testing.T) {
130136 handler := &TermsOfServiceHandler{
131131- Templates: templates,
132132- RegistryURL: "atcr.io",
133133- CompanyName: "AT Container Registry",
134134- Jurisdiction: "State of Texas, United States",
137137+ BaseUIHandler: BaseUIHandler{
138138+ Templates: templates,
139139+ RegistryURL: "atcr.io",
140140+ CompanyName: "AT Container Registry",
141141+ Jurisdiction: "State of Texas, United States",
142142+ },
135143 }
136144137145 req := httptest.NewRequest("GET", "/terms", nil)
+1-1
pkg/appview/handlers/logout.go
···1010// This only clears the current UI session cookie - it does NOT revoke OAuth tokens
1111// OAuth sessions remain intact so other browser tabs/devices stay logged in
1212type LogoutHandler struct {
1313- SessionStore *db.SessionStore
1313+ BaseUIHandler
1414}
15151616func (h *LogoutHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {