Add support to StaticFile so that it works with non-textual files.
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Previously binary files were being interpreted as UTF8 encoded bytestreams this isn't an ideal for pushing out static files such as images. I've modified the StaticFile type so that it explicitly declares the encoding as 'binary' and updated the mechanism used to push back to the client to also be 'binary aware'. I'm not happy with my approach as I've violated the encapsulation of the logic that was previously in the request.respond method, but without further direction on how that object is moving this was the easiest thing to do in order to keep moving with my plan to have a full website ;)
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
1 file+7 added−2 removed
- other:+7 added−2 removed