summary refs log tree commit diff
path: root/synapse/storage/monthly_active_users.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2018-08-23 19:17:08 +0100
committerErik Johnston <erik@matrix.org>2018-08-23 19:17:19 +0100
commitcd77270a669fa827912efd86a0723d85e9e388ed (patch)
treef0ce984b18edf485afdcaad54bbe52c5aa8c2659 /synapse/storage/monthly_active_users.py
parentMerge pull request #3747 from matrix-org/erikj/fix_multiple_sends_notice (diff)
downloadsynapse-cd77270a669fa827912efd86a0723d85e9e388ed.tar.xz
Implement trail users
Diffstat (limited to 'synapse/storage/monthly_active_users.py')
-rw-r--r--synapse/storage/monthly_active_users.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/storage/monthly_active_users.py b/synapse/storage/monthly_active_users.py
index fd3b630bd2..d178f5c5ba 100644
--- a/synapse/storage/monthly_active_users.py
+++ b/synapse/storage/monthly_active_users.py
@@ -201,6 +201,11 @@ class MonthlyActiveUsersStore(SQLBaseStore):
             user_id(str): the user_id to query
         """
         if self.hs.config.limit_usage_by_mau:
+            is_trial = yield self.is_trial_user(user_id)
+            if is_trial:
+                # we don't track trial users in the MAU table.
+                return
+
             last_seen_timestamp = yield self.user_last_seen_monthly_active(user_id)
             now = self.hs.get_clock().time_msec()