(&self, ids: &mut [Self::IdType])
| 327 | type IdType = UUID; |
| 328 | |
| 329 | fn sort(&self, ids: &mut [Self::IdType]) { |
| 330 | let direction = self.direction.unwrap_or(SortDirection::Ascending); |
| 331 | |
| 332 | ids.sort_by(|a, b| match direction { |
| 333 | SortDirection::Ascending => a.cmp(b), |
| 334 | SortDirection::Descending => b.cmp(a), |
| 335 | }); |
| 336 | } |
| 337 | } |
| 338 | |
| 339 | #[cfg(test)] |
no test coverage detected