ring-middleware-format icon indicating copy to clipboard operation
ring-middleware-format copied to clipboard

If response map has content-type set, don't override or something

Open Deraen opened this issue 10 years ago • 1 comments

Sometimes user needs to return json as text/plain type (because IE9).

This works:

(-> (ok (cheshire.core/generate-string {:ping "pong"}))
    (content-type "text/plain"))

Source: https://github.com/metosin/ring-middleware-format/issues/5

Deraen avatar Jan 02 '16 18:01 Deraen

Somewhat related: https://github.com/ngrunwald/ring-middleware-format/commit/6f2930789c1bf43c4001bc4fb19fcab284884a99 and https://github.com/ngrunwald/ring-middleware-format/issues/32

Deraen avatar Mar 12 '16 19:03 Deraen