Skip to content

audit fixes (2)

audit fixes (2) #3602

This check has been archived and is scheduled for deletion. Learn more about checks retention
GitHub Actions / clippy failed Sep 20, 2023 in 1s

reviewdog [clippy] report

reported by reviewdog 🐶

Findings (4)

dex/farm/src/base_functions.rs|227 col 9| warning: unneeded return statement
--> dex/farm/src/base_functions.rs:227:9
|
227 | return migrated_amount;
| ^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: #[warn(clippy::needless_return)] on by default
= help: remove return
farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs|72 col 9| warning: unneeded return statement
--> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
|
72 | return migrated_amount;
| ^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: #[warn(clippy::needless_return)] on by default
= help: remove return
farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs|72 col 9| warning: unneeded return statement
--> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
|
72 | return migrated_amount;
| ^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: #[warn(clippy::needless_return)] on by default
= help: remove return
dex/farm/src/base_functions.rs|227 col 9| warning: unneeded return statement
--> dex/farm/src/base_functions.rs:227:9
|
227 | return migrated_amount;
| ^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: #[warn(clippy::needless_return)] on by default
= help: remove return

Filtered Findings (14)

dex/farm/src/lib.rs|121 col 83| warning: redundant clone
--> dex/farm/src/lib.rs:121:83
|
121 | let claim_rewards_result = self.claim_rewards::<Wrapper>(orig_caller.clone());
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/src/lib.rs:121:72
|
121 | let claim_rewards_result = self.claim_rewards::<Wrapper>(orig_caller.clone());
| ^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm-with-locked-rewards/src/lib.rs|172 col 27| warning: redundant clone
--> dex/farm-with-locked-rewards/src/lib.rs:172:27
|
172 | rewards.amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm-with-locked-rewards/src/lib.rs:172:13
|
172 | rewards.amount.clone(),
| ^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs|49 col 24| warning: redundant clone
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:49:24
|
49 | orig_caller.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:49:13
|
49 | orig_caller.clone(),
| ^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs|52 col 54| warning: redundant clone
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:52:54
|
52 | exit_attributes.staking_farm_token_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:52:13
|
52 | exit_attributes.staking_farm_token_amount.clone(),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
locked-asset/proxy_dex/src/proxy_farm.rs|169 col 17| warning: redundant clone
--> locked-asset/proxy_dex/src/proxy_farm.rs:169:17
|
169 | .clone()
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> locked-asset/proxy_dex/src/proxy_farm.rs:168:13
|
168 | / full_wrapped_farm_attributes
169 | | .clone()
| |^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs|186 col 33| warning: redundant clone
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:33
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:18
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm-with-locked-rewards/src/lib.rs|172 col 27| warning: redundant clone
--> dex/farm-with-locked-rewards/src/lib.rs:172:27
|
172 | rewards.amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm-with-locked-rewards/src/lib.rs:172:13
|
172 | rewards.amount.clone(),
| ^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
locked-asset/proxy_dex/src/proxy_farm.rs|169 col 17| warning: redundant clone
--> locked-asset/proxy_dex/src/proxy_farm.rs:169:17
|
169 | .clone()
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> locked-asset/proxy_dex/src/proxy_farm.rs:168:13
|
168 | / full_wrapped_farm_attributes
169 | | .clone()
| |
^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs|186 col 33| warning: redundant clone
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:33
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:18
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs|186 col 33| warning: redundant clone
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:33
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:18
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs|186 col 33| warning: redundant clone
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:33
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/tests/farm_setup/farm_rewards_distr_setup.rs:186:18
|
186 | &farm_out_amount.clone(),
| ^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs|49 col 24| warning: redundant clone
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:49:24
|
49 | orig_caller.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:49:13
|
49 | orig_caller.clone(),
| ^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default
farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs|52 col 54| warning: redundant clone
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:52:54
|
52 | exit_attributes.staking_farm_token_amount.clone(),
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> farm-staking/farm-staking-proxy/src/proxy_actions/unstake.rs:52:13
|
52 | exit_attributes.staking_farm_token_amount.clone(),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
dex/farm/src/lib.rs|121 col 83| warning: redundant clone
--> dex/farm/src/lib.rs:121:83
|
121 | let claim_rewards_result = self.claim_rewards::<Wrapper>(orig_caller.clone());
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> dex/farm/src/lib.rs:121:72
|
121 | let claim_rewards_result = self.claim_rewards::<Wrapper>(orig_caller.clone());
| ^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: #[warn(clippy::redundant_clone)] on by default

Annotations

Check warning on line 227 in dex/farm/src/base_functions.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

[clippy] dex/farm/src/base_functions.rs#L227

warning: unneeded `return` statement
   --> dex/farm/src/base_functions.rs:227:9
    |
227 |         return migrated_amount;
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
    = help: remove `return`
Raw output
dex/farm/src/base_functions.rs:227:9:w:warning: unneeded `return` statement
   --> dex/farm/src/base_functions.rs:227:9
    |
227 |         return migrated_amount;
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
    = help: remove `return`


__END__

Check warning on line 72 in farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

[clippy] farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs#L72

warning: unneeded `return` statement
  --> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
   |
72 |         return migrated_amount;
   |         ^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
   = note: `#[warn(clippy::needless_return)]` on by default
   = help: remove `return`
Raw output
farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9:w:warning: unneeded `return` statement
  --> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
   |
72 |         return migrated_amount;
   |         ^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
   = note: `#[warn(clippy::needless_return)]` on by default
   = help: remove `return`


__END__

Check warning on line 72 in farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

[clippy] farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs#L72

warning: unneeded `return` statement
  --> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
   |
72 |         return migrated_amount;
   |         ^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
   = note: `#[warn(clippy::needless_return)]` on by default
   = help: remove `return`
Raw output
farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9:w:warning: unneeded `return` statement
  --> farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs:72:9
   |
72 |         return migrated_amount;
   |         ^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
   = note: `#[warn(clippy::needless_return)]` on by default
   = help: remove `return`


__END__

Check warning on line 227 in dex/farm/src/base_functions.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

[clippy] dex/farm/src/base_functions.rs#L227

warning: unneeded `return` statement
   --> dex/farm/src/base_functions.rs:227:9
    |
227 |         return migrated_amount;
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
    = help: remove `return`
Raw output
dex/farm/src/base_functions.rs:227:9:w:warning: unneeded `return` statement
   --> dex/farm/src/base_functions.rs:227:9
    |
227 |         return migrated_amount;
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
    = help: remove `return`


__END__