ruma-api-macros: Slight simplification of api/attribute.rs
This commit is contained in:
parent
6ea5b9b7a1
commit
eab2374253
@ -33,16 +33,10 @@ impl Meta {
|
||||
syn::Path {
|
||||
leading_colon: None,
|
||||
segments,
|
||||
} => {
|
||||
if segments.len() == 1 && segments[0].ident == "ruma_api" {
|
||||
Some(
|
||||
} if segments.len() == 1 && segments[0].ident == "ruma_api" => Some(
|
||||
attr.parse_args()
|
||||
.expect("ruma_api! could not parse request field attributes"),
|
||||
)
|
||||
} else {
|
||||
None
|
||||
}
|
||||
}
|
||||
),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user