update and test twitch clip downloading
This commit is contained in:
+5
-5
@@ -15,7 +15,7 @@ class Database:
|
||||
self.CURSOR = self.CONN.cursor()
|
||||
|
||||
if self.table == "vods":
|
||||
self.columns = "id, date, title, gamename, downloaded, uploaded_yt, chat_upload_yt"
|
||||
self.columns = "id, date, title, gamename, downloaded, uploaded_yt, chats_upload_yt"
|
||||
elif self.table == "clips":
|
||||
self.columns = "slug, date, title, gamename, clip_by, view_count, downloaded, uploaded_yt, shorts_upload_yt"
|
||||
|
||||
@@ -53,7 +53,7 @@ class Database:
|
||||
gamename TEXT NOT NULL,
|
||||
downloaded INTEGER NOT NULL,
|
||||
uploaded_yt INTEGER NOT NULL,
|
||||
chat_upload_yt INTEGER NOT NULL
|
||||
chats_upload_yt INTEGER NOT NULL
|
||||
)
|
||||
"""
|
||||
)
|
||||
@@ -80,7 +80,7 @@ class Database:
|
||||
def mark_as_uploaded_shorts_chats(self, record_id: int):
|
||||
"""Flags a specific row record to uploaded (1)."""
|
||||
|
||||
set_sql = "chat_upload_yt"
|
||||
set_sql = "chats_upload_yt"
|
||||
if self.table == "clips":
|
||||
set_sql = "shorts_uploaded_yt"
|
||||
|
||||
@@ -94,12 +94,12 @@ class Database:
|
||||
def mark_as_downloaded(self, record_id: int):
|
||||
"""Updates the downloaded status to True (1) for a specific record ID."""
|
||||
|
||||
self.__mark_as(record_id, "download")
|
||||
self.__mark_as(record_id, "downloaded")
|
||||
|
||||
def get_unuploaded_shorts_chats(self):
|
||||
"""Retrieves all clip rows remaining to be chat uploaded."""
|
||||
|
||||
where_sql = "chat_upload_yt"
|
||||
where_sql = "chats_upload_yt"
|
||||
if self.table == "clips":
|
||||
where_sql = "shorts_uploaded_yt"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user