From d69ba0a5f3892f3087bf8a73d2b1afbe732b0244 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1t=C3=A9=20Bartus?= Date: Thu, 31 Dec 2020 15:52:47 +0100 Subject: [PATCH] [ticket/16671] Code style fixes PHPBB3-16671 --- phpBB/phpbb/attachment/delete.php | 8 ++-- phpBB/phpbb/attachment/upload.php | 16 +++---- phpBB/phpbb/avatar/driver/upload.php | 2 +- phpBB/phpbb/composer/extension_manager.php | 4 +- .../console/command/extension/install.php | 2 +- .../console/command/extension/manage.php | 2 +- .../console/command/extension/remove.php | 2 +- .../console/command/extension/update.php | 2 +- phpBB/phpbb/filesystem/helper.php | 4 +- .../module/install_data/task/add_modules.php | 2 +- phpBB/phpbb/storage/adapter/local.php | 10 ++--- phpBB/phpbb/storage/adapter_factory.php | 12 +++--- phpBB/phpbb/storage/file_info.php | 2 +- phpBB/phpbb/storage/storage.php | 42 +++++++++---------- 14 files changed, 55 insertions(+), 55 deletions(-) diff --git a/phpBB/phpbb/attachment/delete.php b/phpBB/phpbb/attachment/delete.php index ec89cd5218..80fd6b62d4 100644 --- a/phpBB/phpbb/attachment/delete.php +++ b/phpBB/phpbb/attachment/delete.php @@ -13,10 +13,10 @@ namespace phpbb\attachment; -use \phpbb\config\config; -use \phpbb\db\driver\driver_interface; -use \phpbb\event\dispatcher; -use \phpbb\storage\storage; +use phpbb\config\config; +use phpbb\db\driver\driver_interface; +use phpbb\event\dispatcher; +use phpbb\storage\storage; /** * Attachment delete class diff --git a/phpBB/phpbb/attachment/upload.php b/phpBB/phpbb/attachment/upload.php index d823e17bd0..b72f43860c 100644 --- a/phpBB/phpbb/attachment/upload.php +++ b/phpBB/phpbb/attachment/upload.php @@ -14,14 +14,14 @@ namespace phpbb\attachment; use phpbb\auth\auth; -use \phpbb\cache\service; -use \phpbb\config\config; -use \phpbb\event\dispatcher; -use \phpbb\language\language; -use \phpbb\plupload\plupload; -use \phpbb\storage\storage; -use \phpbb\filesystem\temp; -use \phpbb\user; +use phpbb\cache\service; +use phpbb\config\config; +use phpbb\event\dispatcher; +use phpbb\language\language; +use phpbb\plupload\plupload; +use phpbb\storage\storage; +use phpbb\filesystem\temp; +use phpbb\user; /** * Attachment upload class diff --git a/phpBB/phpbb/avatar/driver/upload.php b/phpBB/phpbb/avatar/driver/upload.php index da1e78cb83..c0f15536ae 100644 --- a/phpBB/phpbb/avatar/driver/upload.php +++ b/phpBB/phpbb/avatar/driver/upload.php @@ -14,7 +14,7 @@ namespace phpbb\avatar\driver; use bantu\IniGetWrapper\IniGetWrapper; -use \phpbb\storage\exception\exception as storage_exception; +use phpbb\storage\exception\exception as storage_exception; /** * Handles avatars uploaded to the board diff --git a/phpBB/phpbb/composer/extension_manager.php b/phpBB/phpbb/composer/extension_manager.php index 5c056c2136..f9d5ddb956 100644 --- a/phpBB/phpbb/composer/extension_manager.php +++ b/phpBB/phpbb/composer/extension_manager.php @@ -29,12 +29,12 @@ use phpbb\filesystem\filesystem; class extension_manager extends manager { /** - * @var \phpbb\extension\manager + * @var manager */ protected $extension_manager; /** - * @var \phpbb\filesystem\filesystem + * @var filesystem */ protected $filesystem; diff --git a/phpBB/phpbb/console/command/extension/install.php b/phpBB/phpbb/console/command/extension/install.php index bbed53be30..8b11f9b5c8 100644 --- a/phpBB/phpbb/console/command/extension/install.php +++ b/phpBB/phpbb/console/command/extension/install.php @@ -31,7 +31,7 @@ class install extends \phpbb\console\command\command protected $manager; /** - * @var \phpbb\language\language + * @var language */ protected $language; diff --git a/phpBB/phpbb/console/command/extension/manage.php b/phpBB/phpbb/console/command/extension/manage.php index cd8bbc1a7d..fcd30cc707 100644 --- a/phpBB/phpbb/console/command/extension/manage.php +++ b/phpBB/phpbb/console/command/extension/manage.php @@ -30,7 +30,7 @@ class manage extends \phpbb\console\command\command protected $manager; /** - * @var \phpbb\language\language + * @var language */ protected $language; diff --git a/phpBB/phpbb/console/command/extension/remove.php b/phpBB/phpbb/console/command/extension/remove.php index 69d2a62dd9..d2f09657d5 100644 --- a/phpBB/phpbb/console/command/extension/remove.php +++ b/phpBB/phpbb/console/command/extension/remove.php @@ -31,7 +31,7 @@ class remove extends \phpbb\console\command\command protected $manager; /** - * @var \phpbb\language\language + * @var language */ protected $language; diff --git a/phpBB/phpbb/console/command/extension/update.php b/phpBB/phpbb/console/command/extension/update.php index f1479c8b0d..a8236e5366 100644 --- a/phpBB/phpbb/console/command/extension/update.php +++ b/phpBB/phpbb/console/command/extension/update.php @@ -30,7 +30,7 @@ class update extends \phpbb\console\command\command protected $manager; /** - * @var \phpbb\language\language + * @var language */ protected $language; diff --git a/phpBB/phpbb/filesystem/helper.php b/phpBB/phpbb/filesystem/helper.php index 24103e8318..0843e077ad 100644 --- a/phpBB/phpbb/filesystem/helper.php +++ b/phpBB/phpbb/filesystem/helper.php @@ -18,7 +18,7 @@ use Symfony\Component\Filesystem\Filesystem as symfony_filesystem; class helper { /** - * @var \Symfony\Component\Filesystem\Filesystem + * @var symfony_filesystem */ protected static $symfony_filesystem; @@ -371,7 +371,7 @@ class helper /** * Get an instance of symfony's filesystem object. * - * @return \Symfony\Component\Filesystem\Filesystem Symfony filesystem + * @return symfony_filesystem Symfony filesystem */ protected static function get_symfony_filesystem() { diff --git a/phpBB/phpbb/install/module/install_data/task/add_modules.php b/phpBB/phpbb/install/module/install_data/task/add_modules.php index 3dfdab356c..c010ab2000 100644 --- a/phpBB/phpbb/install/module/install_data/task/add_modules.php +++ b/phpBB/phpbb/install/module/install_data/task/add_modules.php @@ -31,7 +31,7 @@ class add_modules extends \phpbb\install\task_base protected $db; /** - * @var \phpbb\install\helper\iohandler\iohandler_interface + * @var iohandler_interface */ protected $iohandler; diff --git a/phpBB/phpbb/storage/adapter/local.php b/phpBB/phpbb/storage/adapter/local.php index 132c16230d..6471194090 100644 --- a/phpBB/phpbb/storage/adapter/local.php +++ b/phpBB/phpbb/storage/adapter/local.php @@ -29,21 +29,21 @@ class local implements adapter_interface, stream_interface /** * Filesystem component * - * @var \phpbb\filesystem\filesystem + * @var filesystem */ protected $filesystem; /** * FastImageSize * - * @var \FastImageSize\FastImageSize + * @var FastImageSize */ protected $imagesize; /** * Mimetype Guesser component * - * @var \phpbb\mimetype\guesser + * @var guesser */ protected $mimetype_guesser; @@ -209,7 +209,7 @@ class local implements adapter_interface, stream_interface * * @param string $path The directory path * - * @throws \phpbb\storage\exception\exception On any directory creation failure + * @throws exception On any directory creation failure */ protected function create_dir($path) { @@ -342,7 +342,7 @@ class local implements adapter_interface, stream_interface * * @param string $path The file * - * @throws \phpbb\storage\exception\exception When cannot get size + * @throws exception When cannot get size * * @return array Properties */ diff --git a/phpBB/phpbb/storage/adapter_factory.php b/phpBB/phpbb/storage/adapter_factory.php index 6be702c0c8..5d08bfa7c2 100644 --- a/phpBB/phpbb/storage/adapter_factory.php +++ b/phpBB/phpbb/storage/adapter_factory.php @@ -20,26 +20,26 @@ use phpbb\storage\exception\exception; class adapter_factory { /** - * @var \phpbb\config\config + * @var config */ protected $config; /** - * @var \phpbb\di\service_collection + * @var service_collection */ protected $adapters; /** - * @var \phpbb\di\service_collection + * @var service_collection */ protected $providers; /** * Constructor * - * @param \phpbb\config\config $config - * @param \phpbb\di\service_collection $adapters - * @param \phpbb\di\service_collection $providers + * @param config $config + * @param service_collection $adapters + * @param service_collection $providers */ public function __construct(config $config, service_collection $adapters, service_collection $providers) { diff --git a/phpBB/phpbb/storage/file_info.php b/phpBB/phpbb/storage/file_info.php index 6b10e6892a..25981cc9c9 100644 --- a/phpBB/phpbb/storage/file_info.php +++ b/phpBB/phpbb/storage/file_info.php @@ -19,7 +19,7 @@ use phpbb\storage\adapter\adapter_interface; class file_info { /** - * @var \phpbb\storage\adapter\adapter_interface + * @var adapter_interface */ protected $adapter; diff --git a/phpBB/phpbb/storage/storage.php b/phpBB/phpbb/storage/storage.php index 93f81791cd..6e4768ed9e 100644 --- a/phpBB/phpbb/storage/storage.php +++ b/phpBB/phpbb/storage/storage.php @@ -28,13 +28,13 @@ class storage protected $adapter; /** - * @var \phpbb\db\driver\driver_interface + * @var db */ protected $db; /** * Cache driver - * @var \phpbb\cache\driver\driver_interface + * @var cache */ protected $cache; @@ -56,8 +56,8 @@ class storage /** * Constructor * - * @param \phpbb\db\driver\driver_interface $db - * @param \phpbb\cache\driver\driver_interface $cache + * @param db $db + * @param cache $cache * @param \phpbb\storage\adapter_factory $factory * @param string $storage_name * @param string $storage_table @@ -102,8 +102,8 @@ class storage * @param string path The file to be written to. * @param string content The data to write into the file. * - * @throws \phpbb\storage\exception\exception When the file already exists - * When the file cannot be written + * @throws exception When the file already exists + * When the file cannot be written */ public function put_contents($path, $content) { @@ -121,8 +121,8 @@ class storage * * @param string $path The file to read * - * @throws \phpbb\storage\exception\exception When the file doesn't exist - * When cannot read file contents + * @throws exception When the file doesn't exist + * When cannot read file contents * * @return string Returns file contents * @@ -155,8 +155,8 @@ class storage * * @param string $path file/directory to remove * - * @throws \phpbb\storage\exception\exception When removal fails - * When the file doesn't exist + * @throws exception When removal fails + * When the file doesn't exist */ public function delete($path) { @@ -175,9 +175,9 @@ class storage * @param string $path_orig The original file/direcotry * @param string $path_dest The target file/directory * - * @throws \phpbb\storage\exception\exception When the file doesn't exist - * When target exists - * When file/directory cannot be renamed + * @throws exception When the file doesn't exist + * When target exists + * When file/directory cannot be renamed */ public function rename($path_orig, $path_dest) { @@ -201,9 +201,9 @@ class storage * @param string $path_orig The original filename * @param string $path_dest The target filename * - * @throws \phpbb\storage\exception\exception When the file doesn't exist - * When target exists - * When the file cannot be copied + * @throws exception When the file doesn't exist + * When target exists + * When the file cannot be copied */ public function copy($path_orig, $path_dest) { @@ -226,8 +226,8 @@ class storage * * @param string $path File to read * - * @throws \phpbb\storage\exception\exception When the file doesn't exist - * When unable to open file + * @throws exception When the file doesn't exist + * When unable to open file * * @return resource Returns a file pointer */ @@ -262,8 +262,8 @@ class storage * @param string $path The target file * @param resource $resource The resource * - * @throws \phpbb\storage\exception\exception When the file exist - * When target file cannot be created + * @throws exception When the file exist + * When target file cannot be created */ public function write_stream($path, $resource) { @@ -484,7 +484,7 @@ class storage /** * Get space available in bytes * - * @throws \phpbb\storage\exception\exception When unable to retrieve available storage space + * @throws exception When unable to retrieve available storage space * * @return float Returns available space */