Skip to content

fix(core): omit @nonExposed fields from nested filter and sort inputs - #809

Open
o-mid wants to merge 1 commit into
theam:mainfrom
o-mid:fix/nested-non-exposed-graphql
Open

o-mid wants to merge 1 commit into
theam:mainfrom
o-mid:fix/nested-non-exposed-graphql

Conversation

@o-mid

@o-mid o-mid commented Sep 28, 2026 •

Copy link
Copy Markdown

Summary

Nested GraphQL filter and sort inputs were still offering fields marked @nonExposed. The builders looked the exclusion list up by property name (address). Decorators store it under the class name (Address). A nested class that is not an entity, read model, command, or query never gets a config entry, so the list also has to be read from that class's own decorator metadata.

The shared class input cache is filled without those exclusions. Query generation runs before mutations, and a stripped cached input would hide the field on command inputs as well.

Semver: patch. Method signatures are unchanged. Nested *PropertyFilter and *PropertySortBy inputs no longer include the hidden fields.

Fixes #702

Test plan

  • Filter test failed on main before the fix (internalCode was still on the nested filter type)
  • cd packages/core && rushx test (333 passing)
  • cd packages/core && rushx lint:fix

Filter and sort builders looked up non-exposed fields by the property name. Decorators store that list under the class name, and a nested class with no class decorator only keeps it on its own metadata. Those fields are now left out of the nested inputs. The shared class input type is unchanged.

Fixes theam#702

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: nonExposedGraphQLMetadataKey lookup uses property name instead of class name for nested types

1 participant