Optimize CheckInternetConnection() code
Add settings classes