Ben 11 months ago
parent
commit
79319a1c90
2 changed files with 2 additions and 1 deletions
  1. 2 1
      app.py
  2. 0 0
      data.json

+ 2 - 1
app.py

@@ -15,7 +15,8 @@ def extract():
     result = db.search(lambda x: x["url"] == url)
     if result:
         logging.info("find from data.json, so return")
-        return result[0]
+        if result[0].get("result"):
+            return result[0].get("result")
     logging.info(f"url: ${url}")
     with yt_dlp.YoutubeDL({"flat-playlist": True, "extract_flat": "flat-playlist"}) as ydl:
         info = ydl.extract_info(url, download=False)

File diff suppressed because it is too large
+ 0 - 0
data.json


Some files were not shown because too many files changed in this diff