summaryrefslogtreecommitdiff
path: root/protocols/FacebookRM/src/process.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/FacebookRM/src/process.cpp')
-rw-r--r--protocols/FacebookRM/src/process.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/protocols/FacebookRM/src/process.cpp b/protocols/FacebookRM/src/process.cpp
index c06143bc69..0fd44897ce 100644
--- a/protocols/FacebookRM/src/process.cpp
+++ b/protocols/FacebookRM/src/process.cpp
@@ -552,9 +552,6 @@ void FacebookProto::ProcessNotifications(void*)
if (isOffline())
return;
- if (!getByte(FACEBOOK_KEY_EVENT_NOTIFICATIONS_ENABLE, DEFAULT_EVENT_NOTIFICATIONS_ENABLE))
- return;
-
facy.handle_entry("notifications");
// Get notifications
@@ -577,6 +574,11 @@ void FacebookProto::ProcessNotifications(void*)
p->parse_notifications(&(resp.data), &notifications);
delete p;
+ facy.notifications_count_ = notifications.size();
+
+ if (!getByte(FACEBOOK_KEY_EVENT_NOTIFICATIONS_ENABLE, DEFAULT_EVENT_NOTIFICATIONS_ENABLE))
+ return;
+
for(std::vector<facebook_notification*>::size_type i=0; i<notifications.size(); i++)
{
debugLogA(" Got notification: %s", notifications[i]->text.c_str());