Skip to content

Commit

Permalink
fix: use a dataclass for reddit posts
Browse files Browse the repository at this point in the history
Should fix jbsparrow#426
  • Loading branch information
NTFSvolume committed Jan 5, 2025
1 parent eeb027b commit 7398245
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cyberdrop_dl/scraper/crawlers/reddit_crawler.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from __future__ import annotations

import contextlib
from dataclasses import dataclass
from typing import TYPE_CHECKING, ClassVar

import asyncpraw
Expand All @@ -23,10 +24,11 @@
from cyberdrop_dl.managers.manager import Manager


@dataclass
class Post:
id: int = None
title: str
date: int
id: int = None

@property
def number(self):
Expand Down

0 comments on commit 7398245

Please sign in to comment.