Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
stream_subscription: Mark notifications disabled for web public users.
Aman Agrawal190f481f495d
diff --git a/zerver/lib/stream_subscription.py b/zerver/lib/stream_subscription.pyindex 2185083fbdf..214460bb9b1 100644--- a/zerver/lib/stream_subscription.py+++ b/zerver/lib/stream_subscription.py@@ -1,4 +1,4 @@-from typing import Any, Dict, List, Tuple+from typing import Any, Dict, List, Optional, Tuplefrom django.db.models.query import QuerySet@@ -74,7 +74,7 @@ def num_subscribers_for_stream_id(stream_id: int) -> int:).count()-def handle_stream_notifications_compatibility(user_profile: UserProfile,+def handle_stream_notifications_compatibility(user_profile: Optional[UserProfile],stream_dict: Dict[str, Any],notification_settings_null: bool) -> None:# Old versions of the mobile apps don't support `None` as a@@ -96,4 +96,4 @@ def handle_stream_notifications_compatibility(user_profile: UserProfile,if stream_dict[notification_type] is not None:continuetarget_attr = "enable_stream_" + notification_type- stream_dict[notification_type] = getattr(user_profile, target_attr)+ stream_dict[notification_type] = False if user_profile is None else getattr(user_profile, target_attr)