diff options
author | friendica <info@friendica.com> | 2014-09-16 19:07:19 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-09-16 19:07:19 -0700 |
commit | c4608d4c827881b0f0fa5e2031de3fbd5b0568d7 (patch) | |
tree | a590f2a9e6774806fa7acfd573790e99cf014875 /include/zot.php | |
parent | 6a82ccecd08e84dff0f4e3198693823d7019c6d2 (diff) | |
download | volse-hubzilla-c4608d4c827881b0f0fa5e2031de3fbd5b0568d7.tar.gz volse-hubzilla-c4608d4c827881b0f0fa5e2031de3fbd5b0568d7.tar.bz2 volse-hubzilla-c4608d4c827881b0f0fa5e2031de3fbd5b0568d7.zip |
just mark dead hubloc deleted - don't remove them. This could cause problems. Also clean up fetch_url/post_url header option
Diffstat (limited to 'include/zot.php')
-rw-r--r-- | include/zot.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/zot.php b/include/zot.php index add44e288..b7ffe14e4 100644 --- a/include/zot.php +++ b/include/zot.php @@ -1844,8 +1844,10 @@ function sync_locations($sender,$arr,$absolute = false) { if($absolute && $xisting) { foreach($xisting as $x) { if(! array_key_exists('updated',$x)) { - logger('sync_locations: removing unreferenced hub location ' . $x['hubloc_url']); - $r = q("delete from hubloc where hubloc_id = %d limit 1", + logger('sync_locations: deleting unreferenced hub location ' . $x['hubloc_url']); + $r = q("update hubloc set hubloc_flags = (hubloc_flags ^ %d), hubloc_updated = '%s' where hubloc_id = %d limit 1", + intval(HUBLOC_FLAGS_DELETED), + dbesc(datetime_convert()), intval($x['hubloc_id']) ); $what .= 'removed_hub'; |