- πΊπΈUnited States ksenzee Washington state
Just today I had to work around the absence of a route.isAdmin cache context.
Quoting Wim Leers in #2475749-2: Allow to set #cache metadata in hook_page_attachments() β :
In a follow-up, we should make all
hook_page_attachments()
,hook_page_attachments_alter()
,hook_page_top()
andhook_page_bottom()
implementations set the right cacheability metadata.For example,
quickedit_page_attachments()
only adds its asset library if the current user has the right permission (vary by the'user.permissions'
cache context) and it's not an admin route (no cache context for that yet).
Needs work
11.0 π₯
Last updated
The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
Just today I had to work around the absence of a route.isAdmin cache context.