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

Fix warnings printed by Rocket regarding String as parameter type #1907

Merged
merged 1 commit into from
Jan 9, 2024

Conversation

dtolnay
Copy link
Member

@dtolnay dtolnay commented Jan 9, 2024

I noticed these warnings in the console while testing my governance page changes.

GET /governance/teams/leadership-council text/html:
   >> Matched: (team) GET /governance/<section>/<team> [2]
   >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
   >> `String` is used a parameter guard in src/main.rs:224.
   >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
   >> `String` is used a parameter guard in src/main.rs:225.
   >> Outcome: Success(200 OK)

GET /tools/install text/html:
   >> Matched: (subject) GET /<category>/<subject> [4]
   >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
   >> `String` is used a parameter guard in src/main.rs:260.
   >> Outcome: Success(200 OK)

    GET /governance/teams/leadership-council text/html:
       >> Matched: (team) GET /governance/<section>/<team> [2]
       >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
       >> `String` is used a parameter guard in src/main.rs:224.
       >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
       >> `String` is used a parameter guard in src/main.rs:225.
       >> Outcome: Success(200 OK)

    GET /tools/install text/html:
       >> Matched: (subject) GET /<category>/<subject> [4]
       >> Note: Using `String` as a parameter type is inefficient. Use `&str` instead.
       >> `String` is used a parameter guard in src/main.rs:260.
       >> Outcome: Success(200 OK)
@dtolnay dtolnay requested a review from a team as a code owner January 9, 2024 22:14
@Manishearth Manishearth merged commit e89f301 into rust-lang:master Jan 9, 2024
1 check passed
@dtolnay dtolnay deleted the rocketstring branch January 9, 2024 22:35
@dtolnay dtolnay mentioned this pull request Jan 15, 2024
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.

2 participants