Repository navigation
Mock API: matching, import and Studio fixes - #336
Merged
bryantgillespie merged 1 commit intoNov 6, 2026
Merged
Conversation
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.
Follow-up fixes for #333, from review. They don't block release (#335 is the one that does). Rob, take or leave any of these.
API and matching
engine.ts). Before,/files/*listed above/files/:idanswered/files/1, even though the README says the most specific endpoint answers.parseRequiredQuerynow usesURLSearchParams). Two cases that never matched before:name=Jane+Doe(+is now read as a space).token=abc==(the value was cut at the second=).a=x%26b%3Dyanda=x&b=yapart (endpointKey). They used to get the same key, so a merge import could overwrite the wrong endpoint.foolocally and the file hasfooandfoo-2. Both used to targetfoo-2, the unique constraint failed and the whole import rolled back.12345678901234567890) and keeps the author's formatting.init('app.after')instead of at hook load, so it no longer runs (and logs errors) in CLI commands like bootstrap and migrate. Checked on Directus 12: the collections are created at startup.Studio
adminpath segment./mock/...paths. Before, it would send any method to any project path with your admin session.readyref.Screenshots
Replace import now asks before deleting:
Full video
Test request rejects paths outside
/mock/. In the same screenshot,/files/:idanswers over/files/*even though the wildcard is listed first:Testing
endpointKeyencoding and order, and Copy prefix allocation.pnpm test(38),pnpm validate, eslint and build all pass.Jane+Doequery matching and the large-number body checked over HTTP.Not done
beforeunloadwarning on the endpoint page.engine.ts.