mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[ticket/15342] free_space() now return false if there is any error
PHPBB3-15342
This commit is contained in:
@@ -99,9 +99,7 @@ interface adapter_interface
|
||||
/*
|
||||
* Get space available in bytes.
|
||||
*
|
||||
* @throws \phpbb\storage\exception\exception When unable to retrieve available storage space
|
||||
*
|
||||
* @return int Returns available space
|
||||
* @return mixed Returns available space or null when unable to retrieve available space
|
||||
*/
|
||||
public function free_space();
|
||||
}
|
||||
|
@@ -432,11 +432,6 @@ class local implements adapter_interface, stream_interface
|
||||
{
|
||||
$free_space = @disk_free_space($this->root_path);
|
||||
|
||||
if ($free_space === false)
|
||||
{
|
||||
throw new exception('STORAGE_CANNOT_GET_FREE_SPACE');
|
||||
}
|
||||
|
||||
return (int) $free_space;
|
||||
return $free_space;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user