Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: query interface with fragments #3238

Open
wants to merge 13 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: integration tests
  • Loading branch information
MedHeikelBouzayene committed Jan 5, 2025
commit 1c87ef8c62007727e94797588e43aa6c5664b6fb
2 changes: 1 addition & 1 deletion src/core/jit/transform/graphql.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
fn transform(&self, mut plan: Self::Value) -> Valid<Self::Value, Self::Error> {
let interfaces = match plan.interfaces {
Some(ref interfaces) => interfaces,
None => &HashSet::new(),

Check warning on line 53 in src/core/jit/transform/graphql.rs

View check run for this annotation

Codecov / codecov/patch

src/core/jit/transform/graphql.rs#L53

Added line #L53 was not covered by tests
};
compute_selection_set(&mut plan.selection, interfaces);

Expand Down Expand Up @@ -105,8 +105,8 @@
//Don't force user to query the type and get it automatically
if is_parent_interface {
normal_fields.push("__typename".to_owned());
normal_fields.push(fragments_set.join(" "));
}
normal_fields.push(fragments_set.join(" "));
Some(format!("{{ {} }}", normal_fields.join(" ")))
}

Expand Down
Loading