Fixed the bug of generating federation sdl. #96

This commit is contained in:
Sunli 2020-05-19 10:32:08 +08:00
parent 273aecb6bf
commit a87b7f1a71

View File

@ -467,17 +467,10 @@ impl Registry {
keys,
..
} => {
if name.starts_with("__") {
return;
}
if name == "_Service" {
return;
}
if fields.len() == 4 {
if name == &self.query_type && fields.len() == 4 {
// Is empty query root, only __schema, __type, _service, _entities fields
return;
}
if *extends {
write!(sdl, "extend ").ok();
}