fix sql query and provide setting to hide online status

This commit is contained in:
friendica
2014-01-28 16:16:55 -08:00
parent 6e22aa25cc
commit 8efac0cfd6
3 changed files with 11 additions and 1 deletions

View File

@@ -50,6 +50,7 @@ function ping_init(&$a) {
if($r) {
foreach($r as $rr) {
q("update chatpresence set cp_last = '%s' where cp_id = %d limit 1",
dbesc(datetime_convert()),
intval($rr['cp_id'])
);
}
@@ -67,7 +68,6 @@ function ping_init(&$a) {
q("delete from chatpresence where cp_last < UTC_TIMESTAMP() - INTERVAL 2 MINUTE");
if((! local_user()) || ($result['invalid'])) {
echo json_encode($result);
killme();