mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-08 04:18:52 +00:00
[ticket/17198] Use https instead of http as default in remote avatar
PHPBB3-17198
This commit is contained in:
parent
2d3781f285
commit
a04af20806
2 changed files with 3 additions and 2 deletions
|
@ -62,7 +62,7 @@ class remote extends \phpbb\avatar\driver\driver
|
||||||
|
|
||||||
if (!preg_match('#^(http|https|ftp)://#i', $url))
|
if (!preg_match('#^(http|https|ftp)://#i', $url))
|
||||||
{
|
{
|
||||||
$url = 'http://' . $url;
|
$url = 'https://' . $url;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!function_exists('validate_data'))
|
if (!function_exists('validate_data'))
|
||||||
|
|
|
@ -27,7 +27,7 @@ class phpbb_avatar_manager_test extends \phpbb_database_test_case
|
||||||
|
|
||||||
protected function setUp(): void
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
global $phpbb_root_path, $phpEx;
|
global $phpbb_dispatcher, $phpbb_root_path, $phpEx;
|
||||||
|
|
||||||
// Mock phpbb_container
|
// Mock phpbb_container
|
||||||
$phpbb_container = $this->createMock('Symfony\Component\DependencyInjection\ContainerInterface');
|
$phpbb_container = $this->createMock('Symfony\Component\DependencyInjection\ContainerInterface');
|
||||||
|
@ -60,6 +60,7 @@ class phpbb_avatar_manager_test extends \phpbb_database_test_case
|
||||||
$imagesize = new \FastImageSize\FastImageSize();
|
$imagesize = new \FastImageSize\FastImageSize();
|
||||||
|
|
||||||
$dispatcher = new phpbb_mock_event_dispatcher();
|
$dispatcher = new phpbb_mock_event_dispatcher();
|
||||||
|
$phpbb_dispatcher = $dispatcher;
|
||||||
|
|
||||||
// $this->avatar_foobar will be needed later on
|
// $this->avatar_foobar will be needed later on
|
||||||
$this->avatar_foobar = $this->getMockBuilder('\phpbb\avatar\driver\foobar')
|
$this->avatar_foobar = $this->getMockBuilder('\phpbb\avatar\driver\foobar')
|
||||||
|
|
Loading…
Add table
Reference in a new issue