forked from rDrama/rDrama
fix profile songs in localhost
parent
44e9085d8d
commit
92b77735ae
|
@ -800,6 +800,7 @@ def settings_song_change(v):
|
|||
return redirect("/settings/personal?msg=Profile Anthem successfully updated!")
|
||||
|
||||
|
||||
if YOUTUBE_KEY != DEFAULT_CONFIG_VALUE:
|
||||
req = requests.get(f"https://www.googleapis.com/youtube/v3/videos?id={id}&key={YOUTUBE_KEY}&part=contentDetails", timeout=5).json()
|
||||
duration = req['items'][0]['contentDetails']['duration']
|
||||
if duration == 'P0D':
|
||||
|
|
Loading…
Reference in New Issue