diff --git a/core/lib/Drupal/Core/Field/FieldUpdateActionBase.php b/core/lib/Drupal/Core/Field/FieldUpdateActionBase.php index ed184e9eb3f3d8102e17c7d9fe41eb5a46ba56d7..a5a0f71b202950bb60d2fb25d0fe1a733c20e37c 100644 --- a/core/lib/Drupal/Core/Field/FieldUpdateActionBase.php +++ b/core/lib/Drupal/Core/Field/FieldUpdateActionBase.php @@ -53,7 +53,7 @@ public function access($object, ?AccountInterface $account = NULL, $return_as_ob $result = $object->access('update', $account, TRUE); foreach ($this->getFieldsToUpdate() as $field => $value) { - $result->andIf($object->{$field}->access('edit', $account, TRUE)); + $result = $result->andIf($object->{$field}->access('edit', $account, TRUE)); } return $return_as_object ? $result : $result->isAllowed(); diff --git a/core/modules/views/tests/src/FunctionalJavascript/ExposedFilterAJAXTest.php b/core/modules/views/tests/src/FunctionalJavascript/ExposedFilterAJAXTest.php index 6d61ecef80a0757ca90b2ddd80de2be5ba70678f..af7cad9e287d808e4f23561c4227a2ed7a641e07 100644 --- a/core/modules/views/tests/src/FunctionalJavascript/ExposedFilterAJAXTest.php +++ b/core/modules/views/tests/src/FunctionalJavascript/ExposedFilterAJAXTest.php @@ -78,6 +78,14 @@ protected function setUp(): void { * Tests if exposed filtering via AJAX works for the "Content" View. */ public function testExposedFiltering(): void { + // Create an account that can update the sticky flag. + $user = $this->drupalCreateUser([ + 'access content overview', + 'administer nodes', + 'edit any page content', + ]); + $this->drupalLogin($user); + // Visit the View page. $this->drupalGet('admin/content');