From afdf8a014236452e098ab1266c9a9315824f8103 Mon Sep 17 00:00:00 2001 From: Julio Capote Date: Mon, 19 Dec 2022 10:41:43 -0500 Subject: url helpers, cgi response format --- http/server.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'http') diff --git a/http/server.go b/http/server.go index 5d0a689..b3d3c9b 100644 --- a/http/server.go +++ b/http/server.go @@ -39,6 +39,7 @@ func (s *Server) Start(zapWriter io.Writer) { actorParam := c.Param("actor") resource, _ := s.registry.Profile(actorParam) if resource != nil { + c.Writer.Header().Set("Content-Type", "application/activity+json") c.JSON(http.StatusOK, resource) } else { c.JSON(http.StatusNotFound, nil) @@ -68,6 +69,7 @@ func (s *Server) Start(zapWriter io.Writer) { resource, _ = s.registry.Outbox(actorParam) } if resource != nil { + c.Writer.Header().Set("Content-Type", "application/activity+json") c.JSON(http.StatusOK, resource) } else { c.JSON(http.StatusNotFound, nil) -- cgit v1.2.3