generalise the site black|white allow lists, also add a channel black|white list for future use
This commit is contained in:
+2
-12
@@ -554,18 +554,8 @@ function zot_gethub($arr,$multiple = false) {
|
||||
|
||||
if($arr['guid'] && $arr['guid_sig'] && $arr['url'] && $arr['url_sig']) {
|
||||
|
||||
$blacklisted = false;
|
||||
$bl1 = get_config('system','blacklisted_sites');
|
||||
if(is_array($bl1) && $bl1) {
|
||||
foreach($bl1 as $bl) {
|
||||
if($bl && strpos($arr['url'],$bl) !== false) {
|
||||
$blacklisted = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if($blacklisted) {
|
||||
logger('zot_gethub: blacklisted site: ' . $arr['url']);
|
||||
if(! check_siteallowed($arr['url'])) {
|
||||
logger('blacklisted site: ' . $arr['url']);
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user