Repository navigation
[BUGFIX lts] LinkTo: do not read unknown properties from models - #21771
Merged
NullVoxPopuli merged 2 commits intoNov 2, 2026
Merged
NullVoxPopuli merged 2 commits into
NullVoxPopuli merged 2 commits into
Conversation
LinkTo checked whether its last model was a QueryParams object by reading `isQueryParams` from it. Some models throw on unknown properties. WarpDrive records in PolarisMode do this in dev builds, so `<LinkTo @model={{record}}>` failed with "No field named isQueryParams". Check `instanceof QueryParams` instead. Ember no longer creates QueryParams objects itself, and the old `(query-params)` helper created them with `new QueryParams()`, so they still match. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`instanceof QueryParams` rejected custom objects that set `isQueryParams: true`. Check `'isQueryParams' in value` before the read instead. WarpDrive records answer `in` from their schema and do not throw, so they still work. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 26, 2026
ef4
approved these changes
Nov 2, 2026
This was referenced Nov 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
<LinkTo @model={{record}}>crashes in dev builds whenrecordis a WarpDrive record in PolarisMode:LinkTo checks whether its last model is a
QueryParamsobject. It does this by readingisQueryParamsfrom the model. PolarisMode records throw when code reads a field that is not in their schema.This PR checks
'isQueryParams' in valuebefore it reads the property. Custom objects that setisQueryParams: truestill match. WarpDrive records answerinfrom their schema, so they returnfalseand do not throw.The new test passes LinkTo a model that throws on unknown fields. It fails on
mainwith the error above.Found while moving the super-rentals tutorial to PolarisMode.
PolarisMode tutorial PRs
Merge in this order:
ember-sourcemain.<LinkTo @model={{record}}>with PolarisMode records.useRecommendedStorewithout@warp-drive/legacy.Related:
@warp-drive/legacy(merged).🤖 Generated with Claude Code