mirror of
https://github.com/phpbb/phpbb.git
synced 2025-02-22 10:57:56 +01:00
Merge branch '3.1.x'
This commit is contained in:
commit
03eae6fddd
@ -219,6 +219,8 @@ class filespec
|
|||||||
*/
|
*/
|
||||||
static public function get_extension($filename)
|
static public function get_extension($filename)
|
||||||
{
|
{
|
||||||
|
$filename = utf8_basename($filename);
|
||||||
|
|
||||||
if (strpos($filename, '.') === false)
|
if (strpos($filename, '.') === false)
|
||||||
{
|
{
|
||||||
return '';
|
return '';
|
||||||
|
@ -216,6 +216,8 @@ class phpbb_filespec_test extends phpbb_test_case
|
|||||||
array('file.phpbb.gif', 'gif'),
|
array('file.phpbb.gif', 'gif'),
|
||||||
array('file..', ''),
|
array('file..', ''),
|
||||||
array('.file..jpg.webp', 'webp'),
|
array('.file..jpg.webp', 'webp'),
|
||||||
|
array('/test.com/file', ''),
|
||||||
|
array('/test.com/file.gif', 'gif'),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user