diff options
-rw-r--r-- | pydis_site/apps/api/models/bot/metricity.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/pydis_site/apps/api/models/bot/metricity.py b/pydis_site/apps/api/models/bot/metricity.py index bb1db708..e7fc92fc 100644 --- a/pydis_site/apps/api/models/bot/metricity.py +++ b/pydis_site/apps/api/models/bot/metricity.py @@ -55,15 +55,15 @@ class Metricity: self.cursor.execute( """ SELECT - COUNT(*) - FROM ( - SELECT - (floor((extract('epoch' from created_at) / %d )) * %d) AS interval - FROM messages - WHERE - author_id='%s' - AND NOT is_deleted - GROUP BY interval + COUNT(*) + FROM ( + SELECT + (floor((extract('epoch' from created_at) / %d )) * %d) AS interval + FROM messages + WHERE + author_id='%s' + AND NOT is_deleted + GROUP BY interval ) block_query; """, [BLOCK_INTERVAL, BLOCK_INTERVAL, user_id] |