1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

[ticket/14285] Fix tests

PHPBB3-14285
This commit is contained in:
rubencm
2021-03-21 20:02:45 +01:00
parent 925502a92f
commit f66c1d9e1e
5 changed files with 21 additions and 261 deletions

View File

@@ -45,7 +45,7 @@ class attachment extends controller
/** @var dispatcher_interface */
protected $dispatcher;
/** @var \phpbb\language\language */
/** @var language */
protected $language;
/** @var request */
@@ -122,8 +122,8 @@ class attachment extends controller
$attachment['physical_filename'] = utf8_basename($attachment['physical_filename']);
if (!$attachment['in_message'] && !$this->config['allow_attachments'] ||
$attachment['in_message'] && !$this->config['allow_pm_attach'])
if ((!$attachment['in_message'] && !$this->config['allow_attachments']) ||
($attachment['in_message'] && !$this->config['allow_pm_attach']))
{
throw new http_exception(404, 'ATTACHMENT_FUNCTIONALITY_DISABLED');
}

View File

@@ -62,9 +62,9 @@ class controller
*
* @param string $file File path
*
* @throws \phpbb\exception\http_exception when can't access $file
* @throws http_exception when can't access $file
*
* @return \Symfony\Component\HttpFoundation\StreamedResponse a Symfony response object
* @return StreamedResponse a Symfony response object
*/
public function handle($file)
{