diff --git a/scrapthechan/parsers/dvach.py b/scrapthechan/parsers/dvach.py index b5d2592..f9f7076 100644 --- a/scrapthechan/parsers/dvach.py +++ b/scrapthechan/parsers/dvach.py @@ -26,9 +26,9 @@ class DvachParser(Parser): @property def op(self) -> Optional[str]: op = "" - if 'sub' in self._op_post: + if 'subject' in self._op_post: op = f"{self._op_post['subject']}\n" - if 'com' in self._op_post: + if 'comment' in self._op_post: op += self._op_post['comment'] return op if not op == "" else None @@ -36,7 +36,9 @@ class DvachParser(Parser): if not 'files' in post: return None files = [] for f in post['files']: - if match(f['fullname'], r"^image\.\w{1,4}$") is None: + if 'sticker' in f: + continue + if match(r"^image\.\w+$", f['fullname']) is None: fullname = f['fullname'] else: fullname = f['name']