CupertinoWebSocket: Allow close codes as defined in RFC 6455 #1294
Labels
package:cupertino_http
Issues related to package:cupertino_http
type-bug
Incorrect behavior (everything from a crash to more subtle misbehavior)
This is a follow-up from issue #1203.
At this moment, the
CupertinoWebSocket.close
will throw if passed non-null code parameter that's not equal to 1000 or in [3000, 4999] range.This is not in line with the RFC 6455 specification, that allows additional codes in range 1000-1010 for client use.
The WHATWG specification of the WebSocket close operation is less permissive, but since:
I believe that it should permit all client-side codes permitted by RFC 6455.
I'm fine with providing a PR for applying this change.
The text was updated successfully, but these errors were encountered: