prisma-engines
9df9a92c - refactor: clean up some code in `QueryExt::select_ids` (#5520)

Commit
285 days ago
refactor: clean up some code in `QueryExt::select_ids` (#5520) 1. There was no need to use `drain` since we own the vector itself and not a mutable reference to it, just `for row in rows` would have been fine. 2. Rather than creating a second vector and using a loop to push the transformed values, using `map` is more idiomatic (and more efficient in this case, too, since the vec was created with `Vec::new` instead of `Vec::with_capacity`). 3. The TODO comment seemed outdated, the `Select` passed to this function already has the `traceparent` applied externally by the caller (see `filter_ids`).
Author
Parents
Loading