Skip to content

Commit

Permalink
Async response is JSON
Browse files Browse the repository at this point in the history
  • Loading branch information
vincent99 committed Feb 7, 2024
1 parent ae73de1 commit 727668c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ func (s *Server) run(rw http.ResponseWriter, req *http.Request) {
go func() {
_, _ = s.runner.Run(ctx, prg, os.Environ(), string(body))
}()
rw.Header().Set("Content-Type", "application/json")
err := json.NewEncoder(rw).Encode(map[string]any{
"id": id,
})
Expand Down

0 comments on commit 727668c

Please sign in to comment.