From f63733a131d458c78de375720b72079d1a1c7d37 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Tue, 21 Jan 2020 13:07:41 -0800 Subject: [PATCH] fix z_dns_check for ipv6, map poll objects --- Zotlabs/Lib/Activity.php | 11 +++- images/koala2.svg | 116 +++++++++++++++++++++++++++++++++++++++ include/network.php | 7 +-- 3 files changed, 126 insertions(+), 8 deletions(-) create mode 100644 images/koala2.svg diff --git a/Zotlabs/Lib/Activity.php b/Zotlabs/Lib/Activity.php index 9c5ba1a89..a9529cda8 100644 --- a/Zotlabs/Lib/Activity.php +++ b/Zotlabs/Lib/Activity.php @@ -1175,9 +1175,6 @@ class Activity { static function activity_obj_mapper($obj) { - if (strpos($obj,'/') === false) { - return $obj; - } $objs = [ 'http://activitystrea.ms/schema/1.0/note' => 'Note', @@ -1199,6 +1196,14 @@ class Activity { call_hooks('activity_obj_mapper',$objs); + if ($obj === 'Answer') { + return 'Note'; + } + + if (strpos($obj,'/') === false) { + return $obj; + } + if (array_key_exists($obj,$objs)) { return $objs[$obj]; } diff --git a/images/koala2.svg b/images/koala2.svg new file mode 100644 index 000000000..22d7b9fab --- /dev/null +++ b/images/koala2.svg @@ -0,0 +1,116 @@ + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + diff --git a/include/network.php b/include/network.php index 10d299880..01504f2d5 100644 --- a/include/network.php +++ b/include/network.php @@ -515,10 +515,7 @@ function z_dns_check($h,$check_mx = 0) { // Use config values from memory as this can be called during setup // before a database or even any config structure exists. - if(is_array(\App::$config) && array_key_exists('system',\App::$config) - && is_array(\App::$config['system']) - && array_key_exists('do_not_check_dns',\App::$config['system']) - && \App::$config['system']['do_not_check_dns']) + if(is_array(App::$config) && array_path_exists('system/do_not_check_dns', App::$config) && App::$config['system']['do_not_check_dns']) return true; // This will match either Windows or Mac ('Darwin') @@ -531,7 +528,7 @@ function z_dns_check($h,$check_mx = 0) { // Otherwise we will assume dns_get_record() works as documented - $opts = DNS_A + DNS_CNAME + DNS_PTR; + $opts = DNS_A + DNS_CNAME + DNS_AAAA; if($check_mx) $opts += DNS_MX;