Fix cache metadata bubbling

Created on 29 May 2025, about 1 month ago

Problem/Motivation

The cacheable metadata does not bubble up to the response when \Drupal\jsonapi_menu_items\Resource\MenuItemsResource::process() calls \Drupal\jsonapi_menu_items\Resource\MenuItemsResource::getMenuItems() which is really problematic.

Steps to reproduce

Call api/menu_items/main for a menu when the user has no access to any items.

Proposed resolution

Bubble the metadata correctly.

Remaining tasks

User interface changes

None

API changes

Change $cache is now passed by reference to \Drupal\jsonapi_menu_items\Resource\MenuItemsResource::getMenuItems()

Data model changes

None

πŸ› Bug report
Status

Active

Version

1.2

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024