diff --git a/core/lib/Drupal/Component/PhpStorage/FileReadOnlyStorage.php b/core/lib/Drupal/Component/PhpStorage/FileReadOnlyStorage.php index 87bbf2eb96..eee3ac5939 100644 --- a/core/lib/Drupal/Component/PhpStorage/FileReadOnlyStorage.php +++ b/core/lib/Drupal/Component/PhpStorage/FileReadOnlyStorage.php @@ -65,18 +65,11 @@ public function getFullPath($name) { return $this->directory . '/' . $name; } - /** - * {@inheritdoc} - */ - public function writable() { - return FALSE; - } - /** * {@inheritdoc} */ public function writeable() { - @trigger_error(__METHOD__ . '() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. Use \Drupal\Component\PhpStorage\FileReadOnlyStorage::writable() instead. See https://www.drupal.org/node/3155413', E_USER_DEPRECATED); + @trigger_error(__METHOD__ . '() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3155413', E_USER_DEPRECATED); return FALSE; } diff --git a/core/lib/Drupal/Component/PhpStorage/FileStorage.php b/core/lib/Drupal/Component/PhpStorage/FileStorage.php index fc377f0a82..a694144b71 100644 --- a/core/lib/Drupal/Component/PhpStorage/FileStorage.php +++ b/core/lib/Drupal/Component/PhpStorage/FileStorage.php @@ -144,18 +144,11 @@ public function getFullPath($name) { return $this->directory . '/' . $name; } - /** - * {@inheritdoc} - */ - public function writable() { - return TRUE; - } - /** * {@inheritdoc} */ public function writeable() { - @trigger_error(__METHOD__ . '() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. Use \Drupal\Component\PhpStorage\FileStorage::writable() instead. See https://www.drupal.org/node/3155413', E_USER_DEPRECATED); + @trigger_error(__METHOD__ . '() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3155413', E_USER_DEPRECATED); return TRUE; } diff --git a/core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php b/core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php index 097f2d6747..fda37c8298 100644 --- a/core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php +++ b/core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php @@ -51,22 +51,14 @@ public function load($name); */ public function save($name, $code); - /** - * Whether this is a writable storage. - * - * @return bool - * TRUE if writable, otherwise FALSE. - */ - public function writable(); - /** * Whether this is a writable storage. * * @return bool * TRUE if writable, otherwise FALSE. * - * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use - * \Drupal\Component\PhpStorage\PhpStorageInterface::writable() instead. + * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no + * replacement. * * @see https://www.drupal.org/node/3155413 */ diff --git a/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageReadOnlyTest.php b/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageReadOnlyTest.php index 7d21ec35b2..22975ddea4 100644 --- a/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageReadOnlyTest.php +++ b/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageReadOnlyTest.php @@ -85,7 +85,7 @@ public function testReadOnly() { * @group legacy */ public function testWritable() { - $this->expectDeprecation('Drupal\Component\PhpStorage\FileReadOnlyStorage::writeable() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. Use \Drupal\Component\PhpStorage\FileReadOnlyStorage::writable() instead. See https://www.drupal.org/node/3155413'); + $this->expectDeprecation('Drupal\Component\PhpStorage\FileReadOnlyStorage::writeable() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3155413'); $php_read = new FileReadOnlyStorage($this->readonlyStorage); $this->assertFalse($php_read->writeable()); } diff --git a/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageTest.php b/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageTest.php index 0b448f912d..51426a2857 100644 --- a/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageTest.php +++ b/core/tests/Drupal/Tests/Component/PhpStorage/FileStorageTest.php @@ -54,7 +54,7 @@ public function testCRUD() { * @group legacy */ public function testWritable() { - $this->expectDeprecation('Drupal\Component\PhpStorage\FileStorage::writeable() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. Use \Drupal\Component\PhpStorage\FileStorage::writable() instead. See https://www.drupal.org/node/3155413'); + $this->expectDeprecation('Drupal\Component\PhpStorage\FileStorage::writeable() is deprecated in drupal:10.1.0 and will be removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3155413'); $php = new FileStorage($this->standardSettings); $this->assertTrue($php->writeable()); }