diff options
author | Luca Casonato <hello@lcas.dev> | 2021-10-04 22:56:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-04 22:56:24 +0200 |
commit | 64a7187238c4f291f254bd6eb58138a3a6534898 (patch) | |
tree | f1d552ffdfab2324e818589b5d357a674dd22a2c /ext/websocket/lib.rs | |
parent | c6ae41fd8701b0fc5735ae4a6fa288f5cb35f03a (diff) |
chore: remove No*Permissions structs (#12316)
These are confusing. They say they are "for users that don't care about
permissions", but that isn't correct. `NoTimersPermissions` disables
permissions instead of enabling them.
I would argue that implementors should decide what permissions they want
themselves, and not take our opinionated permissions struct.
Diffstat (limited to 'ext/websocket/lib.rs')
-rw-r--r-- | ext/websocket/lib.rs | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/ext/websocket/lib.rs b/ext/websocket/lib.rs index dbb88dc8d..ebb2186d0 100644 --- a/ext/websocket/lib.rs +++ b/ext/websocket/lib.rs @@ -59,15 +59,6 @@ pub trait WebSocketPermissions { /// would override previously used alias. pub struct UnsafelyIgnoreCertificateErrors(Option<Vec<String>>); -/// For use with `op_websocket_*` when the user does not want permissions. -pub struct NoWebSocketPermissions; - -impl WebSocketPermissions for NoWebSocketPermissions { - fn check_net_url(&mut self, _url: &url::Url) -> Result<(), AnyError> { - Ok(()) - } -} - type WsStream = WebSocketStream<MaybeTlsStream<TcpStream>>; pub enum WebSocketStreamType { Client { |