summary refs log tree commit diff
path: root/synapse/storage/_base.py
diff options
context:
space:
mode:
authorDan Callahan <danc@element.io>2021-05-14 10:59:10 +0100
committerGitHub <noreply@github.com>2021-05-14 10:59:10 +0100
commit52ed9655edf8849d68a178e1c76040c79824a353 (patch)
tree162265349e646c1e94fadc997dc6b10bb9de8205 /synapse/storage/_base.py
parentRemove superfluous call to bool() (#9986) (diff)
downloadsynapse-52ed9655edf8849d68a178e1c76040c79824a353.tar.xz
Remove unnecessary SystemRandom from SQLBaseStore (#9987)
It's not obvious that instances of SQLBaseStore each need their own
instances of random.SystemRandom(); let's just use random directly.

Introduced by 52839886d664576831462e033b88e5aba4c019e3

Signed-off-by: Dan Callahan <danc@element.io>
Diffstat (limited to 'synapse/storage/_base.py')
-rw-r--r--synapse/storage/_base.py2
1 files changed, 0 insertions, 2 deletions
diff --git a/synapse/storage/_base.py b/synapse/storage/_base.py
index 3d98d3f5f8..0623da9aa1 100644
--- a/synapse/storage/_base.py
+++ b/synapse/storage/_base.py
@@ -14,7 +14,6 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 import logging
-import random
 from abc import ABCMeta
 from typing import TYPE_CHECKING, Any, Collection, Iterable, Optional, Union
 
@@ -44,7 +43,6 @@ class SQLBaseStore(metaclass=ABCMeta):
         self._clock = hs.get_clock()
         self.database_engine = database.engine
         self.db_pool = database
-        self.rand = random.SystemRandom()
 
     def process_replication_rows(
         self,