check internet
refactor and version 1.1.7