Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes for Clippy lints #1758

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fixes for Clippy lints #1758

wants to merge 2 commits into from

Conversation

pitaj
Copy link
Contributor

@pitaj pitaj commented Jan 15, 2024

No description provided.

@@ -45,7 +45,7 @@ impl GlacierCommand {
Some(Token::Quote(s)) => {
let source = s.to_owned();
if source.starts_with("https://gist.github.com/") {
return Ok(Some(GlacierCommand { source }));
Ok(Some(GlacierCommand { source }))
} else {
return Err(toks.error(ParseError::InvalidLink));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this return not removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because clippy didn't say to remove it, but I suppose it may as well be removed. Will do

@@ -72,17 +72,17 @@ impl NominateCommand {
if let Some(Token::Dot) | Some(Token::EndOfLine) = toks.peek_token()? {
toks.next_token()?;
*input = toks;
return Ok(Some(NominateCommand { team, style }));
Ok(Some(NominateCommand { team, style }))
} else {
return Err(toks.error(ParseError::ExpectedEnd));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

@@ -47,20 +47,20 @@ impl PingCommand {
if let Some(Token::Dot) | Some(Token::EndOfLine) = toks.peek_token()? {
toks.next_token()?;
*input = toks;
return Ok(Some(PingCommand { team }));
Ok(Some(PingCommand { team }))
} else {
return Err(toks.error(ParseError::ExpectedEnd));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here

}
_ => {}
}
if args.len() == 2 && args[1] == "backlog_bonanza" {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think leaving this as-is is better for future proofing.

}
_ => {}
}
if args.len() == 2 && args[1] == "planning" {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here.

@apiraino
Copy link
Contributor

apiraino commented May 24, 2024

cc @pitaj in case you have time to tick these pending comments.

In general I am not a big fan of massive linting patches, takes more time to review than prepare the patch :)

(I assume changes have been tested - as far as possible with the triagebot codebase)

Thanks!

EDIT: also pls rebase

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants