Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Change to notif_delay_before_mail
Browse files Browse the repository at this point in the history
  • Loading branch information
Mathieu Velten committed Dec 7, 2023
1 parent 66d867c commit 651b2ab
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions docs/usage/configuration/config_documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -680,11 +680,11 @@ This setting has the following sub-options:
has missed. Disabled by default.
* `notif_for_new_users`: Set to false to disable automatic subscription to email
notifications for new users. Enabled by default.
* `delay_before_mail`: The time to wait before emailing about a notification.
* `notif_delay_before_mail`: The time to wait before emailing about a notification.
This gives the user a chance to view the message via push or an open client.
Defaults to 10 minutes.

*New in Synapse 1.98.0._
_New in Synapse 1.99.0._
* `client_base_url`: Custom URL for client links within the email notifications. By default
links will be based on "https://matrix.to". (This setting used to be called `riot_base_url`;
the old name is still supported for backwards-compatibility but is now deprecated.)
Expand Down
4 changes: 2 additions & 2 deletions synapse/config/emailconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,8 +296,8 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
)
# The amount of time we always wait before ever emailing about a notification
# (to give the user a chance to respond to other push or notice the window)
self.delay_before_mail_ms = Config.parse_duration(
email_config.get("delay_before_mail", "10m")
self.notif_delay_before_mail_ms = Config.parse_duration(
email_config.get("notif_delay_before_mail", "10m")
)

if self.root.account_validity.account_validity_renew_by_email_enabled:
Expand Down
2 changes: 1 addition & 1 deletion synapse/push/emailpusher.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def __init__(self, hs: "HomeServer", pusher_config: PusherConfig, mailer: Mailer
except ValueError:
raise PusherConfigException("Invalid email")

self._delay_before_mail_ms = self.hs.config.email.delay_before_mail_ms
self._delay_before_mail_ms = self.hs.config.email.notif_delay_before_mail_ms

def on_started(self, should_check_for_notifs: bool) -> None:
"""Called when this pusher has been started.
Expand Down

0 comments on commit 651b2ab

Please sign in to comment.