mirror of
https://github.com/filebrowser/filebrowser.git
synced 2026-07-17 16:36:49 +00:00
fix: json escaping
This commit is contained in:
parent
d9f9460c1e
commit
c406bda0c7
1 changed files with 1 additions and 1 deletions
|
|
@ -85,7 +85,7 @@ func handleWithStaticData(w http.ResponseWriter, _ *http.Request, d *data, fSys
|
|||
return http.StatusInternalServerError, err
|
||||
}
|
||||
|
||||
data["Json"] = strings.ReplaceAll(string(b), `'`, `\'`)
|
||||
data["Json"] = template.JS(strings.ReplaceAll(string(b), `'`, `\'`))
|
||||
|
||||
fileContents, err := fs.ReadFile(fSys, file)
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue