aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorredmatrix <redmatrix@redmatrix.me>2015-11-03 19:50:40 -0800
committerredmatrix <redmatrix@redmatrix.me>2015-11-03 19:50:40 -0800
commit2fbfc2a8f176ef6ca9389f04b67e5734596ed0da (patch)
tree0738c93d610b5d3694199764feb7e93db1f8699d /include
parente09b49288fa415c85d5ee1e77218c0b4c2b54a1d (diff)
downloadvolse-hubzilla-2fbfc2a8f176ef6ca9389f04b67e5734596ed0da.tar.gz
volse-hubzilla-2fbfc2a8f176ef6ca9389f04b67e5734596ed0da.tar.bz2
volse-hubzilla-2fbfc2a8f176ef6ca9389f04b67e5734596ed0da.zip
need better peer verification due to re-install issue, this is temporary
Diffstat (limited to 'include')
-rw-r--r--include/Contact.php5
-rw-r--r--include/zot.php5
2 files changed, 7 insertions, 3 deletions
diff --git a/include/Contact.php b/include/Contact.php
index 8e22c608e..3bd5f9936 100644
--- a/include/Contact.php
+++ b/include/Contact.php
@@ -292,7 +292,8 @@ function channel_remove($channel_id, $local = true, $unset_session=true) {
intval($channel_id)
);
-
+ logger('deleting hublocs',LOGGER_DEBUG);
+
$r = q("update hubloc set hubloc_deleted = 1 where hubloc_hash = '%s'",
dbesc($channel['channel_hash'])
);
@@ -349,6 +350,8 @@ function channel_remove($channel_id, $local = true, $unset_session=true) {
}
+ logger('deleting hublocs',LOGGER_DEBUG);
+
$r = q("update hubloc set hubloc_deleted = 1 where hubloc_hash = '%s' and hubloc_url = '%s' ",
dbesc($channel['channel_hash']),
dbesc(z_root())
diff --git a/include/zot.php b/include/zot.php
index b13111f04..d7b865ee8 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -2373,6 +2373,7 @@ function sync_locations($sender, $arr, $absolute = false) {
$changed = true;
}
elseif((! intval($r[0]['hubloc_deleted'])) && (intval($location['deleted']))) {
+ logger('deleting hubloc: ' . $r[0]['hubloc_addr']);
$n = q("update hubloc set hubloc_deleted = 1, hubloc_updated = '%s' where hubloc_id = %d",
dbesc(datetime_convert()),
intval($r[0]['hubloc_id'])
@@ -2427,7 +2428,7 @@ function sync_locations($sender, $arr, $absolute = false) {
if($absolute && $xisting) {
foreach($xisting as $x) {
if(! array_key_exists('updated',$x)) {
- logger('sync_locations: deleting unreferenced hub location ' . $x['hubloc_url']);
+ logger('sync_locations: deleting unreferenced hub location ' . $x['hubloc_addr']);
$r = q("update hubloc set hubloc_deleted = 1, hubloc_updated = '%s' where hubloc_id = %d",
dbesc(datetime_convert()),
intval($x['hubloc_id'])
@@ -2468,7 +2469,7 @@ function zot_encode_locations($channel) {
// so that nobody tries to use it.
if(intval($channel['channel_removed']) && $hub['hubloc_url'] === z_root())
- $hub['hubloc_deleted'] = true;
+ $hub['hubloc_deleted'] = 1;
$ret[] = array(
'host' => $hub['hubloc_host'],