Compare commits
2 commits
3faba4e3fa
...
bba5bef505
Author | SHA1 | Date | |
---|---|---|---|
bba5bef505 | |||
faeaeb4fba |
2 changed files with 6 additions and 3 deletions
5
FORK.md
5
FORK.md
|
@ -4,9 +4,14 @@ This is the outline of the changes done in this fork, compared to Kemal upstream
|
||||||
|
|
||||||
- Default HEAD request removed has been removed. If you wish to provide it,
|
- Default HEAD request removed has been removed. If you wish to provide it,
|
||||||
you must give your own handler.
|
you must give your own handler.
|
||||||
|
- Can not be upstreamed as it would be a breaking change that I did not
|
||||||
|
ask upstream about. This is a very specific issue to the web services I
|
||||||
|
write.
|
||||||
- Fix to prevent overwriting the `content-length` header value when set by the
|
- Fix to prevent overwriting the `content-length` header value when set by the
|
||||||
request handler.
|
request handler.
|
||||||
|
- Could be upstreamed, as it is a single line fix.
|
||||||
- Websockets can be closed via an exception, with support for reasons.
|
- Websockets can be closed via an exception, with support for reasons.
|
||||||
|
- Can not be upstreamed. Same reasoning as the first change.
|
||||||
|
|
||||||
## Installation?
|
## Installation?
|
||||||
|
|
||||||
|
|
|
@ -50,11 +50,9 @@ module Kemal
|
||||||
message = "Exception"
|
message = "Exception"
|
||||||
end
|
end
|
||||||
|
|
||||||
raw = uninitialized UInt8[2]
|
|
||||||
IO::ByteFormat::BigEndian.encode(code, raw.to_slice)
|
|
||||||
socket.not_nil!.close(
|
socket.not_nil!.close(
|
||||||
HTTP::WebSocket::CloseCode.new(code),
|
HTTP::WebSocket::CloseCode.new(code),
|
||||||
message: String.new(raw.to_slice) + message
|
message: message
|
||||||
)
|
)
|
||||||
|
|
||||||
raise error unless error.is_a?(WebsocketError)
|
raise error unless error.is_a?(WebsocketError)
|
||||||
|
|
Loading…
Reference in a new issue