1
0
Fork 0
mirror of https://codeberg.org/icewind/vbsp.git synced 2026-06-03 10:44:07 +02:00

tweak parse_prop for readability

This commit is contained in:
Quaternions 2025-02-14 17:28:17 -08:00
commit bf27b6c892

View file

@ -123,7 +123,7 @@ impl<'a> RawEntity<'a> {
&self,
key: &'static str,
) -> Option<Result<T, EntityParseError>> {
Some(T::parse(self.prop(key)?))
self.prop(key).map(T::parse)
}
pub fn parse<E: Deserialize<'a>>(&self) -> Result<E, VdfError> {