From f765c88ac9476bffa2117c8ce7824483f7ee3a11 Mon Sep 17 00:00:00 2001 From: Tim Abbott Date: Tue, 3 Dec 2013 11:58:52 -0500 Subject: [PATCH] The iPhone app now handles unread counts properly. (imported from commit 4afe4d082d9d575142087e12088a1d563e43096e) --- zerver/views/__init__.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/zerver/views/__init__.py b/zerver/views/__init__.py index 28d2fd3d37..a0cd27c48f 100644 --- a/zerver/views/__init__.py +++ b/zerver/views/__init__.py @@ -852,11 +852,10 @@ def update_pointer_backend(request, user_profile, user_profile.pointer = pointer user_profile.save(update_fields=["pointer"]) - if request.client.name.lower() in ['android', 'iphone']: - # TODO (leo) - # Until we handle the new read counts in the mobile apps natively, - # this is a shim that will mark as read any messages up until the - # pointer move + if request.client.name.lower() in ['android']: + # Until we handle the new read counts in the Android app + # natively, this is a shim that will mark as read any messages + # up until the pointer move UserMessage.objects.filter(user_profile=user_profile, message__id__gt=prev_pointer, message__id__lte=pointer,