Skip to content

Commit

Permalink
Set empty dicts to avoid additional errors when config is invalid
Browse files Browse the repository at this point in the history
  • Loading branch information
tulir committed Feb 24, 2022
1 parent e22fc9e commit a1e5d2c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions reactbot/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ def do_update(self, helper: ConfigUpdateHelper) -> None:

def parse_data(self) -> None:
self.default_flags = re.RegexFlag(0)
self.templates = {}
self.rules = {}

self.default_flags = self._get_flags(self["default_flags"])
self.templates = {name: self._make_template(name, tpl)
for name, tpl in self["templates"].items()}
Expand Down

0 comments on commit a1e5d2c

Please sign in to comment.