diff options
| author | bwarsaw | 2001-07-19 19:21:41 +0000 |
|---|---|---|
| committer | bwarsaw | 2001-07-19 19:21:41 +0000 |
| commit | 4ab27e98ead60cec291ebf1c0b1c313204bcf716 (patch) | |
| tree | acc58aa78583fa8c7b067d3cfb2b32dc83df80fe | |
| parent | 410fc0d6415afc62087ed269e8c1d68db8fb507b (diff) | |
| download | mailman-4ab27e98ead60cec291ebf1c0b1c313204bcf716.tar.gz mailman-4ab27e98ead60cec291ebf1c0b1c313204bcf716.tar.zst mailman-4ab27e98ead60cec291ebf1c0b1c313204bcf716.zip | |
GetConfigInfo(): Do specific hasattr() tests instead of catching
AttributeErrors, which can mask real bugs.
| -rw-r--r-- | Mailman/MailList.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/Mailman/MailList.py b/Mailman/MailList.py index 53e88fb07..eff9697fb 100644 --- a/Mailman/MailList.py +++ b/Mailman/MailList.py @@ -354,12 +354,10 @@ class MailList(MailCommandHandler, HTMLFormatter, Deliverer, ListAdmin, def GetConfigInfo(self): info = {} for gui in self._gui: - try: + if hasattr(gui, 'GetConfigCategory') and \ + hasattr(gui, 'GetConfigInfo'): key = gui.GetConfigCategory()[0] value = gui.GetConfigInfo(self) - except AttributeError: - pass - else: info[key] = value return info |
