From 0916c10bcc68ddcd23bf7feceb2acf02813eb7c9 Mon Sep 17 00:00:00 2001 From: John Donaldson Date: Thu, 7 Nov 2019 15:59:22 +0000 Subject: [PATCH] Fixing handling of multiple authors --- VERSION | 2 +- devel/moth.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index eb39e53..4772543 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -3.3 +3.3.2 diff --git a/devel/moth.py b/devel/moth.py index 1875bd7..7161029 100644 --- a/devel/moth.py +++ b/devel/moth.py @@ -174,6 +174,10 @@ class Puzzle: def handle_header_key(self, key, val): if key == 'author': self.authors.append(val) + elif key == 'authors': + if not isinstance(val, list): + raise ValueError("Authors must be a list, got %s, instead" & (type(val),)) + self.authors = list(val) elif key == 'summary': self.summary = val elif key == 'answer':