mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-13 06:52:17 -04:00
Use direct references for configuration variables (part 6). (#10916)
This commit is contained in:
parent
8cef1ab2ac
commit
94b620a5ed
54 changed files with 141 additions and 132 deletions
|
@ -679,8 +679,8 @@ class RoomWorkerStore(SQLBaseStore):
|
|||
# policy.
|
||||
if not ret:
|
||||
return {
|
||||
"min_lifetime": self.config.retention_default_min_lifetime,
|
||||
"max_lifetime": self.config.retention_default_max_lifetime,
|
||||
"min_lifetime": self.config.server.retention_default_min_lifetime,
|
||||
"max_lifetime": self.config.server.retention_default_max_lifetime,
|
||||
}
|
||||
|
||||
row = ret[0]
|
||||
|
@ -690,10 +690,10 @@ class RoomWorkerStore(SQLBaseStore):
|
|||
# The default values will be None if no default policy has been defined, or if one
|
||||
# of the attributes is missing from the default policy.
|
||||
if row["min_lifetime"] is None:
|
||||
row["min_lifetime"] = self.config.retention_default_min_lifetime
|
||||
row["min_lifetime"] = self.config.server.retention_default_min_lifetime
|
||||
|
||||
if row["max_lifetime"] is None:
|
||||
row["max_lifetime"] = self.config.retention_default_max_lifetime
|
||||
row["max_lifetime"] = self.config.server.retention_default_max_lifetime
|
||||
|
||||
return row
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue