Use Content-Security-Policy: script nonce (#37232)

Fix #305
This commit is contained in:
wxiaoguang authored and GitHub committed 2026-04-15 20:07:57 +00:00
1 parent 2644bb8490
commit 82bfde2a37
18 files changed
+134 -52

No files matched your search

-2
View File
@@ -63,8 +63,6 @@ type Context struct {
Package *Package
}
type TemplateContext map[string]any
func init() {
web.RegisterResponseStatusProvider[*Base](func(req *http.Request) web_types.ResponseStatusProvider {
return req.Context().Value(BaseContextKey).(*Base)