diff options
| author | mat <git@matdoes.dev> | 2024-09-15 06:52:16 +0000 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2024-09-15 06:52:16 +0000 |
| commit | 2992fc6b4793e00cb35568e6bc42f7bde02463dd (patch) | |
| tree | 15c4af339127d078bd04d3a178d7d4b380683a39 /azalea-buf/src | |
| parent | d5a281bf15a1aad07b0f108d86461eafffa590a0 (diff) | |
| download | azalea-drasl-2992fc6b4793e00cb35568e6bc42f7bde02463dd.tar.xz | |
update simdnbt
Diffstat (limited to 'azalea-buf/src')
| -rwxr-xr-x | azalea-buf/src/read.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/azalea-buf/src/read.rs b/azalea-buf/src/read.rs index d5961c78..882e2bce 100755 --- a/azalea-buf/src/read.rs +++ b/azalea-buf/src/read.rs @@ -344,13 +344,13 @@ impl<T: McBufReadable, const N: usize> McBufReadable for [T; N] { impl McBufReadable for simdnbt::owned::NbtTag { fn read_from(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError> { - Ok(simdnbt::owned::read_tag(buf)?) + Ok(simdnbt::owned::read_tag(buf).map_err(simdnbt::Error::from)?) } } impl McBufReadable for simdnbt::owned::NbtCompound { fn read_from(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError> { - match simdnbt::owned::read_tag(buf)? { + match simdnbt::owned::read_tag(buf).map_err(simdnbt::Error::from)? { simdnbt::owned::NbtTag::Compound(compound) => Ok(compound), _ => Err(BufReadError::Custom("Expected compound tag".to_string())), } |
