Skip to content

Commit

Permalink
feat: remove data functions that panic
Browse files Browse the repository at this point in the history
  • Loading branch information
kitgxrl committed May 15, 2024
1 parent 101193d commit fd8012b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
6 changes: 0 additions & 6 deletions socketio/src/asynchronous/client/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,6 @@ impl Client {
})
}

/// Fetches data given by [`ClientBuilder::data`]
pub fn data<D: Send + Sync + 'static>(&self) -> Arc<D> {
self.try_data()
.expect("Client::data does not match ClientBuilder::data")
}

/// Attempts to fetch data given by [`ClientBuilder::data`]
///
/// None is returned if data was not given or data does not match [`ClientBuilder::data`]
Expand Down
6 changes: 0 additions & 6 deletions socketio/src/client/raw_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,6 @@ impl RawClient {
})
}

/// Fetches data given by [`ClientBuilder::data`]
pub fn data<D: Send + Sync + 'static>(&self) -> Arc<D> {
self.try_data()
.expect("RawClient::data does not match ClientBuilder::data")
}

/// Attempts to fetch data given by [`ClientBuilder::data`]
///
/// None is returned if data was not given or data does not match [`ClientBuilder::data`]
Expand Down

0 comments on commit fd8012b

Please sign in to comment.