Users with "administer nodes" permission but not "view own unpublished content" can no longer view unpublished nodes. This is a regression in 11.1 caused by 🐛 Access cacheability is not correct when "view own unpublished content" is in use Needs work . It is causing simplenews tests to fail.
Setting as Major because it's a regression / BC break - if that's not right then please adjust.
NB I have deduced this by reading the code. I don't actually have a 11.1 site to test against.
Bug is in NodeAccessControlHandler::checkViewAccess()
.
I suggest that before the check on 'view own unpublished content' we add something like this:
if ($account->hasPermission('administer nodes')) {
return AccessResult::allowed()->addCacheableDependency($cacheability);
}
or we could put this if test around the next 3 if tests that return NULL.
if (!$account->hasPermission('administer nodes')) {
}
Active
11.1 🔥
node system
It restores functionality that was present in earlier versions.