5
0
mirror of https://github.com/cwinfo/yggdrasil-map synced 2024-11-22 11:40:28 +00:00

set max_age in cache headers

This commit is contained in:
Arceliar 2018-12-14 23:01:27 -06:00
parent 1805f55cf9
commit 5eb884bdc8

View File

@ -41,5 +41,10 @@ def page_sendGraph():
else: else:
return 'Error: %s' % ret return 'Error: %s' % ret
@app.after_request
def add_header(response):
response.cache_control.max_age = 300
return response
if __name__ == '__main__': if __name__ == '__main__':
app.run(host='localhost', port=3000) app.run(host='localhost', port=3000)