mirror of
https://github.com/YunoHost-Apps/pixelfed_ynh.git
synced 2024-09-03 20:06:04 +02:00
Update AP Helpers
This commit is contained in:
parent
52863d81e6
commit
0ecb4133d5
1 changed files with 4 additions and 0 deletions
|
@ -135,6 +135,10 @@ class Helpers {
|
|||
'127.0.0.1', 'localhost', '::1'
|
||||
];
|
||||
|
||||
if(mb_substr($url, 0, 8) !== 'https://') {
|
||||
return false;
|
||||
}
|
||||
|
||||
$valid = filter_var($url, FILTER_VALIDATE_URL);
|
||||
|
||||
if(in_array(parse_url($valid, PHP_URL_HOST), $localhosts)) {
|
||||
|
|
Loading…
Add table
Reference in a new issue