cast to str
All checks were successful
continuous-integration/drone Build is passing

This commit is contained in:
Roy Olav Purser 2023-07-07 20:29:53 +02:00
parent 9b36a2ed1e
commit 491f81dd2a
Signed by: roypur
GPG Key ID: 90142918D5E59AD3

View File

@ -140,8 +140,8 @@ class MainHandler(tornado.web.RequestHandler):
video_info = VideoInfo()
video_info.ctype = provider_data.ctype()
if handler.direct:
video_info.upstream = provider_data.upstream()
video_info.poster = provider_data.thumbnail()
video_info.upstream = str(provider_data.upstream())
video_info.poster = str(provider_data.thumbnail())
else:
proxied = await handler.proxy.proxy_url(
[
@ -169,6 +169,14 @@ class MainHandler(tornado.web.RequestHandler):
video_info.poster = proxied[2]
return (
if video_info.upstream:
video_info.upstream = str(video_info.upstream)
if video_info.download:
video_info.download = str(video_info.download)
if video_info.poster:
video_info.poster = str(video_info.poster)
if video_info.ctype:
video_info.ctype = str(video_info.ctype)
dataclasses.asdict(video_info),
provider_data.meta(),
provider_data.title(),