diff options
| author | mat <github@matdoes.dev> | 2021-12-17 16:38:14 -0600 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2021-12-17 16:38:14 -0600 |
| commit | 493aae582adbf818dc4cfdbd0390961d36647d77 (patch) | |
| tree | 9ff582af7c4781a78b1a43c603ae771451325e94 /azalea-protocol/src/connect.rs | |
| parent | c4eecaf13a4f8f0a81dc278078727df23caa8411 (diff) | |
| download | azalea-drasl-493aae582adbf818dc4cfdbd0390961d36647d77.tar.xz | |
fix packets
Diffstat (limited to 'azalea-protocol/src/connect.rs')
| -rw-r--r-- | azalea-protocol/src/connect.rs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/azalea-protocol/src/connect.rs b/azalea-protocol/src/connect.rs index cc06eec3..d3617b3f 100644 --- a/azalea-protocol/src/connect.rs +++ b/azalea-protocol/src/connect.rs @@ -76,7 +76,7 @@ impl HandshakeConnection { } pub async fn read(&mut self) -> Result<HandshakePacket, String> { - read_packet::<HandshakePacket>(&self.flow, &mut self.stream, None).await + read_packet::<HandshakePacket, _>(&self.flow, &mut self.stream, None).await } /// Write a packet to the server @@ -87,7 +87,7 @@ impl HandshakeConnection { impl GameConnection { pub async fn read(&mut self) -> Result<GamePacket, String> { - read_packet::<GamePacket>(&self.flow, &mut self.stream, self.compression_threshold).await + read_packet::<GamePacket, _>(&self.flow, &mut self.stream, self.compression_threshold).await } /// Write a packet to the server @@ -98,7 +98,7 @@ impl GameConnection { impl StatusConnection { pub async fn read(&mut self) -> Result<StatusPacket, String> { - read_packet::<StatusPacket>(&self.flow, &mut self.stream, None).await + read_packet::<StatusPacket, _>(&self.flow, &mut self.stream, None).await } /// Write a packet to the server @@ -109,7 +109,8 @@ impl StatusConnection { impl LoginConnection { pub async fn read(&mut self) -> Result<LoginPacket, String> { - read_packet::<LoginPacket>(&self.flow, &mut self.stream, self.compression_threshold).await + read_packet::<LoginPacket, _>(&self.flow, &mut self.stream, self.compression_threshold) + .await } /// Write a packet to the server |
