From e10691abea2a9948e8f4b6d89e1c1c85993aa66c Mon Sep 17 00:00:00 2001 From: hannes Date: Tue, 5 Jan 2016 14:19:33 +0000 Subject: [PATCH 1/2] only count post-notices (i.e. don't include activity-notices in statuses_count in the API) --- classes/Profile.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/classes/Profile.php b/classes/Profile.php index 945d1a74ca..65758f3e36 100644 --- a/classes/Profile.php +++ b/classes/Profile.php @@ -824,6 +824,7 @@ class Profile extends Managed_DataObject $notices = new Notice(); $notices->profile_id = $this->id; + $notices->whereAdd("verb = '".ActivityVerb::POST."'"); $cnt = (int) $notices->count('distinct id'); if (!empty($c)) { @@ -1696,4 +1697,4 @@ class Profile extends Managed_DataObject { return $this->getUser()->getConnectedApps($offset, $limit); } -} +} \ No newline at end of file From 32549cfd8c747ab82f8979d8f180d5290b27c064 Mon Sep 17 00:00:00 2001 From: hannes Date: Tue, 5 Jan 2016 23:29:48 +0000 Subject: [PATCH 2/2] $notices->verb = ActivityVerb::POST; --- classes/Profile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/Profile.php b/classes/Profile.php index 65758f3e36..620772b0a4 100644 --- a/classes/Profile.php +++ b/classes/Profile.php @@ -824,7 +824,7 @@ class Profile extends Managed_DataObject $notices = new Notice(); $notices->profile_id = $this->id; - $notices->whereAdd("verb = '".ActivityVerb::POST."'"); + $notices->verb = ActivityVerb::POST; $cnt = (int) $notices->count('distinct id'); if (!empty($c)) {