In Flask.run, now when the host/port argument is None, it will use its default value.
This commit is contained in:
parent
c93ea5551c
commit
46e7bc7083
1 changed files with 4 additions and 0 deletions
|
|
@ -695,6 +695,10 @@ class Flask(_PackageBoundObject):
|
||||||
information.
|
information.
|
||||||
"""
|
"""
|
||||||
from werkzeug.serving import run_simple
|
from werkzeug.serving import run_simple
|
||||||
|
if host is None:
|
||||||
|
host = '127.0.0.1'
|
||||||
|
if port is None:
|
||||||
|
port = 5000
|
||||||
if debug is not None:
|
if debug is not None:
|
||||||
self.debug = bool(debug)
|
self.debug = bool(debug)
|
||||||
options.setdefault('use_reloader', self.debug)
|
options.setdefault('use_reloader', self.debug)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue