Skip to content

Commit

Permalink
rename is_dep to is_route_param
Browse files Browse the repository at this point in the history
  • Loading branch information
ntBre committed Jan 15, 2025
1 parent ed4a086 commit 7b723cf
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -252,13 +252,13 @@ fn create_diagnostic(
// others need to be converted from `q: str = Query("")` to `q:
// Annotated[str, Query()] = ""` for example, but Depends and
// Security need to stay like `Annotated[str, Depends(callable)]`
let is_dep = !matches!(
let is_route_param = !matches!(
parameter.kind,
FastApiDependency::Depends | FastApiDependency::Security
);

let content = match dependency_call {
Some(dependency_call) if is_dep => {
Some(dependency_call) if is_route_param => {
let kwarg_list = dependency_call
.keyword_arguments
.iter()
Expand Down

0 comments on commit 7b723cf

Please sign in to comment.