1
0
Fork 0

Update AP Helpers

This commit is contained in:
Daniel Supernault 2019-04-04 21:26:10 -06:00
parent 73a9da15f6
commit a07184db58
No known key found for this signature in database
GPG Key ID: 0DEF1C662C9033F7
1 changed files with 5 additions and 2 deletions

View File

@ -148,7 +148,10 @@ class Helpers {
$host = parse_url($valid, PHP_URL_HOST);
if(config('costar.enabled') == true) {
if(in_array($host, config('costar.domain.block')) == true) {
if(
(config('costar.domain.block') != null && in_array($host, config('costar.domain.block')) == true) ||
(config('costar.actor.block') != null && in_array($url, config('costar.actor.block')) == true)
) {
return false;
}
}
@ -163,7 +166,7 @@ class Helpers {
public static function validateLocalUrl($url)
{
$url = self::validateUrl($url);
if($url) {
if($url == true) {
$domain = config('pixelfed.domain.app');
$host = parse_url($url, PHP_URL_HOST);
$url = $domain === $host ? $url : false;