diff options
| author | Kaalleen <36401965+kaalleen@users.noreply.github.com> | 2022-07-04 13:13:05 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-07-04 13:13:05 +0200 |
| commit | 8d9a469ae2c289d2fde46c64d6d6d37e27dc9520 (patch) | |
| tree | b5c9337ff16f90b4fe71f590f33fe6686bf92b40 /lib/threads/palette.py | |
| parent | 4c3a11bb8252aaaeb9abbd7f5f26c43e8a495d6b (diff) | |
Ignore invalid palettes (#1718)
Diffstat (limited to 'lib/threads/palette.py')
| -rw-r--r-- | lib/threads/palette.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/threads/palette.py b/lib/threads/palette.py index 7a6bf153..e0e3a0ab 100644 --- a/lib/threads/palette.py +++ b/lib/threads/palette.py @@ -40,8 +40,11 @@ class ThreadPalette(Set): with open(palette_file, encoding='utf8') as palette: line = palette.readline().strip() + + self.is_gimp_palette = True if line.lower() != "gimp palette": - raise ValueError("Invalid gimp palette header") + self.is_gimp_palette = False + return self.name = palette.readline().strip() if self.name.lower().startswith('name: ink/stitch: '): |
