mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-01-20 04:01:34 -05:00
Merge pull request #3746 from matrix-org/erikj/mau_fixups
Fix MAU invalidation due to missing yield
This commit is contained in:
commit
dddb5aa7bb
1
changelog.d/3746.misc
Normal file
1
changelog.d/3746.misc
Normal file
@ -0,0 +1 @@
|
|||||||
|
Fix MAU cache invalidation due to missing yield
|
@ -147,6 +147,7 @@ class MonthlyActiveUsersStore(SQLBaseStore):
|
|||||||
return count
|
return count
|
||||||
return self.runInteraction("count_users", _count_users)
|
return self.runInteraction("count_users", _count_users)
|
||||||
|
|
||||||
|
@defer.inlineCallbacks
|
||||||
def upsert_monthly_active_user(self, user_id):
|
def upsert_monthly_active_user(self, user_id):
|
||||||
"""
|
"""
|
||||||
Updates or inserts monthly active user member
|
Updates or inserts monthly active user member
|
||||||
@ -155,7 +156,7 @@ class MonthlyActiveUsersStore(SQLBaseStore):
|
|||||||
Deferred[bool]: True if a new entry was created, False if an
|
Deferred[bool]: True if a new entry was created, False if an
|
||||||
existing one was updated.
|
existing one was updated.
|
||||||
"""
|
"""
|
||||||
is_insert = self._simple_upsert(
|
is_insert = yield self._simple_upsert(
|
||||||
desc="upsert_monthly_active_user",
|
desc="upsert_monthly_active_user",
|
||||||
table="monthly_active_users",
|
table="monthly_active_users",
|
||||||
keyvalues={
|
keyvalues={
|
||||||
|
0
tests/server_notices/__init__.py
Normal file
0
tests/server_notices/__init__.py
Normal file
Loading…
Reference in New Issue
Block a user