Clippy cleanup

This commit is contained in:
sunli 2020-04-22 15:03:41 +08:00
parent 027fa368ab
commit ed9486c072
2 changed files with 63 additions and 65 deletions

View File

@ -90,9 +90,8 @@ pub trait ObjectType: OutputValueType {
where where
Self: Send + Sync + Sized, Self: Send + Sync + Sized,
{ {
if name == Self::type_name().as_ref() { if name == Self::type_name().as_ref()
crate::collect_fields(ctx, self, futures) || ctx
} else if ctx
.registry .registry
.implements .implements
.get(Self::type_name().as_ref()) .get(Self::type_name().as_ref())

View File

@ -163,7 +163,7 @@ pub async fn test_multiple_interfaces() {
} }
#[async_std::test] #[async_std::test]
pub async fn test_multiple_objects_in_multiple_interfaces() { pub async fn test_multiple_objects_in_multiple_interfaces() {
struct MyObjOne; struct MyObjOne;
#[async_graphql::Object] #[async_graphql::Object]
@ -240,7 +240,7 @@ pub async fn test_multiple_interfaces() {
}] }]
}) })
); );
} }
#[async_std::test] #[async_std::test]
pub async fn test_interface_field_result() { pub async fn test_interface_field_result() {
@ -286,4 +286,3 @@ pub async fn test_interface_field_result() {
}) })
); );
} }