1
0
Fork 0
mirror of https://codeberg.org/demostf/parser.git synced 2026-06-04 02:24:12 +02:00

compare definitions by index

This commit is contained in:
Robin Appelman 2019-08-29 16:32:15 +02:00
commit 06d53573d4
2 changed files with 5 additions and 4 deletions

View file

@ -69,7 +69,7 @@ impl PacketEntity {
fn get_prop_by_definition(&mut self, definition: &SendPropDefinition) -> Option<&mut SendProp> {
self.props
.iter_mut()
.find(|prop| prop.definition.as_ref().eq(definition))
.find(|prop| prop.definition.index == definition.index)
}
pub fn apply_update(&mut self, props: Vec<SendProp>) {