Skip to content

2.0.0-alpha.44

Pre-release
Pre-release

Choose a tag to compare

@github-actions github-actions released this 20 Nov 16:18

Breaking

  • A route's path must start with its nearest routed ancestor's path followed by / whenever its path, page or page data is written (a new route, a path PATCH, linking a route), else a 422 on path or route.path; existing routes are not re-checked until one of those is written (#602)

Added

  • #[Silverback\RoutePrefix('/announcements')] on a page data class puts a fixed prefix after the nearest routed ancestor's path in every route of that class written through the API, is applied by fixture route generation, and is advertised as routePrefix on the class's Hydra supportedClass (#602)
  • Moving a page or page data to a new parentPage/parentPageData through the API rewrites its route under the new required start (keeping the part after the old one, else its last segment) and its routed descendants' routes, redirecting every old path; a page with no route moves its routed descendants; a taken or invalid new path is a 422 on the changed parent field and nothing is written (#602)

Fixed

  • A cascadeChildPaths route PATCH that would rewrite a descendant onto a path already in use is a 422 on path before anything is written (#602)

Tooling

  • ResidentMemoryTest's fallback tests no longer fail when PHP allocates a memory chunk between two reads of its usage (#602)