intervention-engine / fhir

Generic FHIR server implementation in GoLang.
Apache License 2.0
112 stars 51 forks source link

Paging Links are Incorrect #114

Closed cjduffett closed 7 years ago

cjduffett commented 7 years ago

The paging links returned by the server are URL escaped. Examples in the FHIR spec show them unescaped. See: http://hl7.org/fhir/2017Jan/http.html#paging

cjduffett commented 7 years ago

Further research shows that json.Marshal automatically escapes <,>, and & characters: https://golang.org/pkg/encoding/json/#Marshal

The documentation says this can be disabled by using an Encoder with DisableHTMLEscaping. However, since this Marshaller is called from within the Gin framework I don't know if we can configure that for calls to c.JSON(). We may have to find an alternative way to return the serialized JSON.