feat(server): add Cache and Firebase as keys to JSON publishing

https://github.com/binwiederhier/ntfy/issues/1119
This commit is contained in:
stendler
2024-05-29 21:23:06 +02:00
parent 9d3fc20e58
commit 5211d06f2c
3 changed files with 53 additions and 0 deletions

View File

@@ -1862,6 +1862,12 @@ func (s *Server) transformBodyJSON(next handleFunc) handleFunc {
if m.Call != "" {
r.Header.Set("X-Call", m.Call)
}
if m.Cache != "" {
r.Header.Set("X-Cache", m.Cache)
}
if m.Firebase != "" {
r.Header.Set("X-Firebase", m.Firebase)
}
return next(w, r, v)
}
}