From 72edc9cd6cc066015e35ec32b4f77a08b764558b Mon Sep 17 00:00:00 2001 From: redmatrix Date: Wed, 9 Dec 2015 18:30:30 -0800 Subject: start working on the singleton setting --- include/network.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include/network.php') diff --git a/include/network.php b/include/network.php index 5895d302b..68452c3d1 100644 --- a/include/network.php +++ b/include/network.php @@ -1883,3 +1883,16 @@ function check_channelallowed($hash) { return $retvalue; } +function deliverable_singleton($xchan) { + $r = q("select abook_instance from abook where abook_xchan = '%s' limit 1", + dbesc($xchan['xchan_hash']) + ); + if($r) { + if(! $r[0]['abook_instance']) + return true; + if(strpos($r[0]['abook_instance'],z_root()) !== false) + return true; + } + return false; +} + -- cgit v1.2.3