mirror of
https://git.sr.ht/~cadence/NewLeaf
synced 2024-11-25 00:47:29 +00:00
Fix ggpht response call order
This commit is contained in:
parent
39425f994a
commit
985f0c1c32
2
index.py
2
index.py
@ -101,8 +101,8 @@ class Second(object):
|
|||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
def ggpht(self, *path):
|
def ggpht(self, *path):
|
||||||
with requests.get("https://yt3.ggpht.com/{}".format("/".join(path))) as r:
|
with requests.get("https://yt3.ggpht.com/{}".format("/".join(path))) as r:
|
||||||
cherrypy.response.headers["content-type"] = r.headers["content-type"]
|
|
||||||
r.raise_for_status()
|
r.raise_for_status()
|
||||||
|
cherrypy.response.headers["content-type"] = r.headers["content-type"]
|
||||||
return r
|
return r
|
||||||
|
|
||||||
cherrypy.config.update({"server.socket_port": 3000, "server.socket_host": "0.0.0.0"})
|
cherrypy.config.update({"server.socket_port": 3000, "server.socket_host": "0.0.0.0"})
|
||||||
|
Loading…
Reference in New Issue
Block a user