mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-10 00:26:14 +02:00
Refactor tmpl and blob_excerpt (#32967)
1. do not use `{{/* */}}` to remove spaces, use `{{- -}}`
2. fix "blob_excerpt" endpoint, remove the legacy fragile code: have
tested commit diff and wiki diff
This commit is contained in:
1 parent
2a828e2798
commit
b7260400f8
16 files changed
+108
-132
No files matched your search
@@ -24,7 +24,7 @@ import (
|
||||
func ProtocolMiddlewares() (handlers []any) {
|
||||
// the order is important
|
||||
handlers = append(handlers, ChiRoutePathHandler()) // make sure chi has correct paths
|
||||
handlers = append(handlers, RequestContextHandler()) // // prepare the context and panic recovery
|
||||
handlers = append(handlers, RequestContextHandler()) // prepare the context and panic recovery
|
||||
|
||||
if setting.ReverseProxyLimit > 0 && len(setting.ReverseProxyTrustedProxies) > 0 {
|
||||
handlers = append(handlers, ForwardedHeadersHandler(setting.ReverseProxyLimit, setting.ReverseProxyTrustedProxies))
|
||||
|
||||
Reference in new issue
Block a user