diff options
-rw-r--r-- | pypaste/database.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pypaste/database.py b/pypaste/database.py index dfdd699..186259b 100644 --- a/pypaste/database.py +++ b/pypaste/database.py @@ -69,7 +69,9 @@ class Database: async def storage_use(self) -> Optional[int]: def do(): with sqlite3.connect(self.path) as connection: - return connection.execute("select sum(pastes.size) from pastes") + return connection.execute( + "select sum(pastes.size) from pastes" + ).fetchone() match asyncio.to_thread(do): case int(use): |