From d5df62597b31aca30381deb1a1768c395f588769 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Calvo?= Date: Tue, 7 Aug 2018 01:42:29 +0200 Subject: [PATCH] [ticket/15692] Remove duplicated checks PHPBB3-15692 --- phpBB/phpbb/storage/adapter/local.php | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/phpBB/phpbb/storage/adapter/local.php b/phpBB/phpbb/storage/adapter/local.php index da3950186e..2ea8b8b03e 100644 --- a/phpBB/phpbb/storage/adapter/local.php +++ b/phpBB/phpbb/storage/adapter/local.php @@ -133,11 +133,6 @@ class local implements adapter_interface, stream_interface */ public function get_contents($path) { - if (!$this->exists($path)) - { - throw new exception('STORAGE_FILE_NO_EXIST', $path); - } - $content = @file_get_contents($this->root_path . $this->get_path($path) . $this->get_filename($path)); if ($content === false) @@ -326,11 +321,6 @@ class local implements adapter_interface, stream_interface { $this->ensure_directory_exists($path); - if ($this->exists($path)) - { - throw new exception('STORAGE_FILE_EXISTS', $path); - } - $stream = @fopen($this->root_path . $this->get_path($path) . $this->get_filename($path), 'w+b'); if (!$stream)