Expand Werkzeug Useragent Class
I want to expand werkzeug UserAgent class with one more browser. How can I do it without modifying the source code of werkzeug library? I'm new in python so I have small idea about
Solution 1:
Amazing. Once you ask question the answer comes up itself :)
Flask.request_class
is the answer:
from werkzeug.wrappers import BaseRequest, ETagRequestMixin
classRequest(BaseRequest, ETagRequestMixin):
pass
app =Flask(__name__)
app.request_class = Request
Post a Comment for "Expand Werkzeug Useragent Class"