Update app.py

This commit is contained in:
Bing Chilling 2023-07-29 01:17:37 +00:00
parent d49a9f4a08
commit cc0e92d2dc

5
app.py
View File

@ -38,7 +38,10 @@ def normalize_utf8(s):
# Render the template with compatibility detection. # Render the template with compatibility detection.
def render_template_c(tmpl, **kwargs): def render_template_c(tmpl, **kwargs):
text_browsers = ['w3m', 'Lynx', 'ELinks', 'Links', 'URL/Emacs', 'Emacs'] text_browsers = ['w3m', 'Lynx', 'ELinks', 'Links', 'URL/Emacs', 'Emacs',
'Mozilla/5.0 (compatible; hjdicks)', # abaco, mothra, etc
]
ua = request.headers.get('User-Agent') ua = request.headers.get('User-Agent')
for text_ua in text_browsers: for text_ua in text_browsers: