Skip to content

Commit

Permalink
Merge pull request #844 from CanalTP/fix_equipment_sanitizing
Browse files Browse the repository at this point in the history
[tech] Fix Equipments sanitizing
  • Loading branch information
ArnaudOggy authored Mar 3, 2022
2 parents b6be37b + 3029bdb commit 6e85c45
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
authors = ["Kisio Digital <[email protected]>", "Guillaume Pinot <[email protected]>"]
name = "transit_model"
version = "0.47.0"
version = "0.48.0"
license = "AGPL-3.0-only"
description = "Transit data management"
repository = "https://github.com/CanalTP/transit_model"
Expand Down
6 changes: 6 additions & 0 deletions src/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,9 @@ impl Collections {
if let Some(level_id) = &sl.level_id {
level_id_used.insert(level_id.clone());
}
if let Some(equipment_id) = &sl.equipment_id {
equipments_used.insert(equipment_id.clone());
}
comments_used.extend(&mut sl.comment_links.iter().map(|cl| cl.to_string()));
true
})
Expand Down Expand Up @@ -407,6 +410,9 @@ impl Collections {
if let Some(level_id) = &sa.level_id {
level_id_used.insert(level_id.clone());
}
if let Some(equipment_id) = &sa.equipment_id {
equipments_used.insert(equipment_id.clone());
}
comments_used.extend(&mut sa.comment_links.iter().map(|cl| cl.to_string()));
true
} else {
Expand Down

0 comments on commit 6e85c45

Please sign in to comment.