We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ebfcbd2 commit b453bd5Copy full SHA for b453bd5
core/codegen/src/attribute/route/mod.rs
@@ -266,12 +266,8 @@ fn internal_uri_macro_decl(route: &Route) -> TokenStream {
266
route.attr.method.as_ref().map(|m| m.0.hash(&mut hasher));
267
route.attr.uri.path().hash(&mut hasher);
268
route.attr.uri.query().hash(&mut hasher);
269
- if let Some(data) = &route.attr.data {
270
- data.value.hash(&mut hasher);
271
- }
272
- if let Some(format) = &route.attr.format {
273
- format.0.hash(&mut hasher);
274
+ route.attr.data.as_ref().map(|d| d.value.hash(&mut hasher));
+ route.attr.format.as_ref().map(|f| f.0.hash(&mut hasher));
275
});
276
277
let route_uri = route.attr.uri.to_string();
0 commit comments