Unused variable: data #3881

Closed
opened 2026-04-06 06:44:11 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @Peneheals on 7/4/2018

A usual Gitlab build output produces:

 ---> Running in 7ffe886a95d1
   Compiling bitwarden_rs v0.9.0 (file:///app)
warning: unused variable: `data`
   --> src/api/core/mod.rs:111:37
    |
111 | fn clear_device_token(uuid: String, data: Json<Value>, headers: Headers, conn: DbConn) -> EmptyResult {
    |                                     ^^^^ help: consider using `_data` instead
    |
    = note: #[warn(unused_variables)] on by default

warning: unused variable: `data`
   --> src/api/core/mod.rs:127:35
    |
127 | fn put_device_token(uuid: String, data: Json<Value>, headers: Headers, conn: DbConn) -> JsonResult {
    |                                   ^^^^ help: consider using `_data` instead

    Finished release [optimized] target(s) in 43.63s
Removing intermediate container 7ffe886a95d1```

Is it a bug on our side or in the code? It doesn't break anything, it's just a "fyi" issue.
*Originally created by @Peneheals on 7/4/2018* A usual Gitlab build output produces: ```Step 18/28 : RUN cargo build --release ---> Running in 7ffe886a95d1 Compiling bitwarden_rs v0.9.0 (file:///app) warning: unused variable: `data` --> src/api/core/mod.rs:111:37 | 111 | fn clear_device_token(uuid: String, data: Json<Value>, headers: Headers, conn: DbConn) -> EmptyResult { | ^^^^ help: consider using `_data` instead | = note: #[warn(unused_variables)] on by default warning: unused variable: `data` --> src/api/core/mod.rs:127:35 | 127 | fn put_device_token(uuid: String, data: Json<Value>, headers: Headers, conn: DbConn) -> JsonResult { | ^^^^ help: consider using `_data` instead Finished release [optimized] target(s) in 43.63s Removing intermediate container 7ffe886a95d1``` Is it a bug on our side or in the code? It doesn't break anything, it's just a "fyi" issue.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/vaultwarden#3881