summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2020-09-02 15:03:12 -0400
committerGitHub <noreply@github.com>2020-09-02 15:03:12 -0400
commitc8758cb72fccc5594ce8da7ccd2256315a8aa27e (patch)
tree7fb875d2428139f46c1810ff70b04e361e797a57 /synapse/storage
parentConvert runInteraction to async/await (#8156) (diff)
downloadsynapse-c8758cb72fccc5594ce8da7ccd2256315a8aa27e.tar.xz
Add an overload for simple_select_one_onecol_txn. (#8235)
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/database.py24
1 files changed, 24 insertions, 0 deletions
diff --git a/synapse/storage/database.py b/synapse/storage/database.py
index 8851710d47..78ca6d8346 100644
--- a/synapse/storage/database.py
+++ b/synapse/storage/database.py
@@ -1149,6 +1149,30 @@ class DatabasePool(object):
             allow_none=allow_none,
         )
 
+    @overload
+    @classmethod
+    def simple_select_one_onecol_txn(
+        cls,
+        txn: LoggingTransaction,
+        table: str,
+        keyvalues: Dict[str, Any],
+        retcol: Iterable[str],
+        allow_none: Literal[False] = False,
+    ) -> Any:
+        ...
+
+    @overload
+    @classmethod
+    def simple_select_one_onecol_txn(
+        cls,
+        txn: LoggingTransaction,
+        table: str,
+        keyvalues: Dict[str, Any],
+        retcol: Iterable[str],
+        allow_none: Literal[True] = True,
+    ) -> Optional[Any]:
+        ...
+
     @classmethod
     def simple_select_one_onecol_txn(
         cls,