Merge remote-tracking branch 'origin/master' #183
Clippy Output
37 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 37 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.87.0-nightly (794c12416 2025-02-21)
- cargo 1.87.0-nightly (ce948f461 2025-02-14)
- clippy 0.1.86 (794c12416b 2025-02-21)
Annotations
Check warning on line 52 in scripty_commands/src/cmds/transcribe_message.rs
github-actions / Clippy Output
this `map_or` can be simplified
warning: this `map_or` can be simplified
--> scripty_commands/src/cmds/transcribe_message.rs:50:5
|
50 | if target
| ________^
51 | | .flags
52 | | .map_or(false, |f| f.contains(MessageFlags::IS_VOICE_MESSAGE))
| |______________________________________________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
help: use is_some_and instead
|
52 - .map_or(false, |f| f.contains(MessageFlags::IS_VOICE_MESSAGE))
52 + .is_some_and(|f| f.contains(MessageFlags::IS_VOICE_MESSAGE))
|
Check warning on line 55 in scripty_commands/src/cmds/premium/info.rs
github-actions / Clippy Output
this `map_or` can be simplified
warning: this `map_or` can be simplified
--> scripty_commands/src/cmds/premium/info.rs:55:20
|
55 | let trial_used = res.as_ref().map_or(false, |row| row.trial_used);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
help: use is_some_and instead
|
55 - let trial_used = res.as_ref().map_or(false, |row| row.trial_used);
55 + let trial_used = res.as_ref().is_some_and(|row| row.trial_used);
|
Check warning on line 152 in scripty_commands/src/cmds/join.rs
github-actions / Clippy Output
this `map_or` can be simplified
warning: this `map_or` can be simplified
--> scripty_commands/src/cmds/join.rs:152:19
|
152 | let trial_used = res.as_ref().map_or(false, |row| row.trial_used);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
= note: `#[warn(clippy::unnecessary_map_or)]` on by default
help: use is_some_and instead
|
152 - let trial_used = res.as_ref().map_or(false, |row| row.trial_used);
152 + let trial_used = res.as_ref().is_some_and(|row| row.trial_used);
|
Check warning on line 10 in scripty_webserver/src/auth.rs
github-actions / Clippy Output
field `token` is never read
warning: field `token` is never read
--> scripty_webserver/src/auth.rs:10:6
|
8 | pub struct Authentication {
| -------------- field in this struct
9 | /// The token used for auth.
10 | pub token: String,
| ^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 12 in scripty_commands/src/cmds/premium/mod.rs
github-actions / Clippy Output
unused import: `remove::*`
warning: unused import: `remove::*`
--> scripty_commands/src/cmds/premium/mod.rs:12:9
|
12 | pub use remove::*;
| ^^^^^^^^^
Check warning on line 11 in scripty_commands/src/cmds/premium/mod.rs
github-actions / Clippy Output
unused import: `info::*`
warning: unused import: `info::*`
--> scripty_commands/src/cmds/premium/mod.rs:11:9
|
11 | pub use info::*;
| ^^^^^^^
Check warning on line 10 in scripty_commands/src/cmds/premium/mod.rs
github-actions / Clippy Output
unused import: `claim::*`
warning: unused import: `claim::*`
--> scripty_commands/src/cmds/premium/mod.rs:10:9
|
10 | pub use claim::*;
| ^^^^^^^^
Check warning on line 22 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `verbose::config_verbose`
warning: unused import: `verbose::config_verbose`
--> scripty_commands/src/cmds/config/mod.rs:22:9
|
22 | pub use verbose::config_verbose;
| ^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 21 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `translate::config_translate`
warning: unused import: `translate::config_translate`
--> scripty_commands/src/cmds/config/mod.rs:21:9
|
21 | pub use translate::config_translate;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 20 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `transcribe_voice_messages::config_transcribe_voice_messages`
warning: unused import: `transcribe_voice_messages::config_transcribe_voice_messages`
--> scripty_commands/src/cmds/config/mod.rs:20:9
|
20 | pub use transcribe_voice_messages::config_transcribe_voice_messages;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 19 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `transcribe_video::config_transcribe_video`
warning: unused import: `transcribe_video::config_transcribe_video`
--> scripty_commands/src/cmds/config/mod.rs:19:9
|
19 | pub use transcribe_video::config_transcribe_video;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 18 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `transcribe_only_role::config_transcribe_only_role`
warning: unused import: `transcribe_only_role::config_transcribe_only_role`
--> scripty_commands/src/cmds/config/mod.rs:18:9
|
18 | pub use transcribe_only_role::config_transcribe_only_role;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 17 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `transcribe_audio::config_transcribe_audio`
warning: unused import: `transcribe_audio::config_transcribe_audio`
--> scripty_commands/src/cmds/config/mod.rs:17:9
|
17 | pub use transcribe_audio::config_transcribe_audio;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 13 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `language::config_server_language`
warning: unused import: `language::config_server_language`
--> scripty_commands/src/cmds/config/mod.rs:13:9
|
13 | pub use language::config_server_language;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 12 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `kiai_enabled::config_enable_kiai`
warning: unused import: `kiai_enabled::config_enable_kiai`
--> scripty_commands/src/cmds/config/mod.rs:12:9
|
12 | pub use kiai_enabled::config_enable_kiai;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 11 in scripty_commands/src/cmds/config/mod.rs
github-actions / Clippy Output
unused import: `auto_detect_lang::config_auto_detect_lang`
warning: unused import: `auto_detect_lang::config_auto_detect_lang`
--> scripty_commands/src/cmds/config/mod.rs:11:9
|
11 | pub use auto_detect_lang::config_auto_detect_lang;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 11 in scripty_commands/src/cmds/admin/mod.rs
github-actions / Clippy Output
unused import: `shutdown::shutdown`
warning: unused import: `shutdown::shutdown`
--> scripty_commands/src/cmds/admin/mod.rs:11:9
|
11 | pub use shutdown::shutdown;
| ^^^^^^^^^^^^^^^^^^
Check warning on line 10 in scripty_commands/src/cmds/admin/mod.rs
github-actions / Clippy Output
unused import: `hash_user_id::hash_user_id`
warning: unused import: `hash_user_id::hash_user_id`
--> scripty_commands/src/cmds/admin/mod.rs:10:9
|
10 | pub use hash_user_id::hash_user_id;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 9 in scripty_commands/src/cmds/admin/mod.rs
github-actions / Clippy Output
unused import: `guild_check::*`
warning: unused import: `guild_check::*`
--> scripty_commands/src/cmds/admin/mod.rs:9:9
|
9 | pub use guild_check::*;
| ^^^^^^^^^^^^^^
Check warning on line 8 in scripty_commands/src/cmds/admin/mod.rs
github-actions / Clippy Output
unused import: `cache_info::cache_info`
warning: unused import: `cache_info::cache_info`
--> scripty_commands/src/cmds/admin/mod.rs:8:9
|
8 | pub use cache_info::cache_info;
| ^^^^^^^^^^^^^^^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
Check warning on line 43 in scripty_bot_utils/src/handler/normal/voice_state_update.rs
github-actions / Clippy Output
this `map_or` can be simplified
warning: this `map_or` can be simplified
--> scripty_bot_utils/src/handler/normal/voice_state_update.rs:40:18
|
40 | let is_bot = guild
| ______________________________^
41 | | .members
42 | | .get(&vs.user_id)
43 | | .map_or(false, |m| m.user.bot());
| |____________________________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
help: use is_some_and instead
|
43 - .map_or(false, |m| m.user.bot());
43 + .is_some_and(|m| m.user.bot());
|
Check warning on line 115 in scripty_bot_utils/src/generic_audio_message.rs
github-actions / Clippy Output
called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
--> scripty_bot_utils/src/generic_audio_message.rs:115:53
|
115 | if let Some(ext) = attachment.filename.split('.').last() {
| ^^^^^^ help: try: `next_back()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last
= note: `#[warn(clippy::double_ended_iterator_last)]` on by default
Check warning on line 106 in scripty_bot_utils/src/generic_audio_message.rs
github-actions / Clippy Output
this `map_or` can be simplified
warning: this `map_or` can be simplified
--> scripty_bot_utils/src/generic_audio_message.rs:104:5
|
104 | if msg.flags.map_or(false, |flags| {
| ________^
105 | | flags.contains(MessageFlags::IS_VOICE_MESSAGE)
106 | | }) {
| |______^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
= note: `#[warn(clippy::unnecessary_map_or)]` on by default
help: use is_some_and instead
|
104 - if msg.flags.map_or(false, |flags| {
104 + if msg.flags.is_some_and(|flags| {
|
Check warning on line 168 in scripty_bot_utils/src/entity_block.rs
github-actions / Clippy Output
this function depends on never type fallback being `()`
warning: this function depends on never type fallback being `()`
--> scripty_bot_utils/src/entity_block.rs:168:1
|
168 | pub async fn add_blocked_guild(guild_id: GuildId, reason: Option<String>) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in Rust 2024 and in a future release in all editions!
= note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/never-type-fallback.html>
= help: specify the types explicitly
note: in edition 2024, the requirement `!: scripty_redis::redis::FromRedisValue` will fail
--> scripty_bot_utils/src/entity_block.rs:185:4
|
185 | .set(
| ^^^
help: use `()` annotations to avoid fallback changes
|
185 | .set::<_, _, ()>(
| ++++++++++++
Check warning on line 138 in scripty_bot_utils/src/entity_block.rs
github-actions / Clippy Output
this function depends on never type fallback being `()`
warning: this function depends on never type fallback being `()`
--> scripty_bot_utils/src/entity_block.rs:138:1
|
138 | pub async fn add_blocked_user(user_id: UserId, reason: Option<String>) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in Rust 2024 and in a future release in all editions!
= note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/never-type-fallback.html>
= help: specify the types explicitly
note: in edition 2024, the requirement `!: scripty_redis::redis::FromRedisValue` will fail
--> scripty_bot_utils/src/entity_block.rs:155:4
|
155 | .set(
| ^^^
help: use `()` annotations to avoid fallback changes
|
155 | .set::<_, _, ()>(
| ++++++++++++