try
This commit is contained in:
@@ -340,10 +340,9 @@ func buildDiagramsNetURL(r *http.Request, id string, xml string) string {
|
|||||||
}
|
}
|
||||||
base := fmt.Sprintf("%s://%s/diagram?id=%s", scheme, r.Host, url.QueryEscape(id))
|
base := fmt.Sprintf("%s://%s/diagram?id=%s", scheme, r.Host, url.QueryEscape(id))
|
||||||
// Request AWS library for custom shapes (e.g., aws4) to render correctly.
|
// Request AWS library for custom shapes (e.g., aws4) to render correctly.
|
||||||
// Provide only the fragment (#U) with an encoded URL because some self-hosted builds only read that token.
|
// Provide only the fragment (#U) with a raw URL because some self-hosted builds only read that token and expect it
|
||||||
// Keeping it encoded avoids header bloat and keeps characters safe inside the fragment.
|
// unescaped (mirroring the desktop/open-url behavior).
|
||||||
encoded := url.QueryEscape(base)
|
redirect := fmt.Sprintf("%s/?splash=0&ui=min&libs=aws4#U%s", drawioBaseURL, base)
|
||||||
redirect := fmt.Sprintf("%s/?splash=0&ui=min&libs=aws4#U%s", drawioBaseURL, encoded)
|
|
||||||
_ = xml // kept for signature compatibility; may be used in future fallbacks
|
_ = xml // kept for signature compatibility; may be used in future fallbacks
|
||||||
return redirect
|
return redirect
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user