Commit 76d8c57
committed
refactor: clean up some code in
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 the second vector and using a loop to push
transformed values, using `map` is more idiomatic (and efficient in
this case, too, since the vec was created with `Vec::new` instead of
`Vec::with_capacity`).
3. The TODO comment seemed outdated, there are no queries to add tracing
too in this function.QueryExt::select_ids
1 parent c238eea commit 76d8c57
1 file changed
Lines changed: 8 additions & 10 deletions
Lines changed: 8 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
135 | 135 | | |
136 | 136 | | |
137 | 137 | | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
148 | 146 | | |
149 | 147 | | |
150 | 148 | | |
| |||
0 commit comments