mirror of
https://github.com/andrewkdinh/fund-indicators.git
synced 2024-11-21 13:34:20 -08:00
Update Functions.py
This commit is contained in:
parent
fd4b3e831d
commit
2dd60c81a7
@ -152,7 +152,7 @@ def isConnected():
|
|||||||
import socket # To check internet connection
|
import socket # To check internet connection
|
||||||
try:
|
try:
|
||||||
# connect to the host -- tells us if the host is actually reachable
|
# connect to the host -- tells us if the host is actually reachable
|
||||||
socket.setdefaulttimeout(timeout)
|
socket.setdefaulttimeout(5)
|
||||||
socket.create_connection(('1.1.1.1', 53))
|
socket.create_connection(('1.1.1.1', 53))
|
||||||
print('Internet connection is good')
|
print('Internet connection is good')
|
||||||
return True
|
return True
|
||||||
|
Loading…
Reference in New Issue
Block a user