Skip to content

Commit e80c192

Browse files
committed
Rust: Use async closure instead of async block
1 parent 46cd62b commit e80c192

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

rust/ql/test/library-tests/dataflow/sources/web_frameworks.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ mod warp_test {
248248

249249
// A route with parameter and `then`
250250
let then_route = warp::path::param().then( // $ Alert[rust/summary/taint-sources]
251-
|a: String| async move {
251+
async move |a: String| {
252252
sink(a); // $ MISSING: hasTaintFlow
253253

254254
"".to_string()
@@ -257,8 +257,8 @@ mod warp_test {
257257

258258
// A route with parameter and `and_then`
259259
let and_then_route = warp::path::param().and_then( // $ Alert[rust/summary/taint-sources]
260-
| id: u64 |
261-
async move {
260+
async move | id: u64 |
261+
{
262262
if id != 0 {
263263
sink(id); // $ MISSING: hasTaintFlow
264264
Ok("".to_string())

0 commit comments

Comments
 (0)