Skip to content

Commit 73740f6

Browse files
committed
remove: empty loop
1 parent 31ba915 commit 73740f6

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

frameworks/Rust/hyperlane/src/route.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,7 @@ pub async fn queries(controller_data: ControllerData) {
3434
.min(ROW_LIMIT as Queries)
3535
.max(1);
3636
let db_pool: DbPoolConnection = get_db_connection().await;
37-
for _ in 0..queries {}
38-
let futures: Vec<_> = (0..queries)
39-
.map(|_| async { random_world_row(&db_pool).await })
40-
.collect();
41-
let data = join_all(futures).await;
37+
let data: Vec<QueryRow> = get_some_row_id(queries, &db_pool).await;
4238
let _ = controller_data
4339
.set_response_body(serde_json::to_string(&data).unwrap_or_default())
4440
.await;

0 commit comments

Comments
 (0)