Update main.py
This commit is contained in:
parent
4111d1dff2
commit
36880c988f
2
main.py
2
main.py
|
@ -250,7 +250,7 @@ if __name__ == "__main__":
|
||||||
def startup_server(scheme, address, port):
|
def startup_server(scheme, address, port):
|
||||||
import webbrowser
|
import webbrowser
|
||||||
if os.name == 'nt' and address == '0.0.0.0':
|
if os.name == 'nt' and address == '0.0.0.0':
|
||||||
address = '127.0.0.1'
|
log.info(address)
|
||||||
if ':' in address:
|
if ':' in address:
|
||||||
address = "[{}]".format(address)
|
address = "[{}]".format(address)
|
||||||
webbrowser.open(f"{scheme}://{address}:{port}")
|
webbrowser.open(f"{scheme}://{address}:{port}")
|
||||||
|
|
Loading…
Reference in New Issue