๐ค Ping me on Twitter
if you like this project
It uses TCP to try to connect to Chrome and Firefox (fallback) captive portal detection servers.
๐ Please visit the full documentation if you want to learn the details.
use std::time::Duration;
use online::*;
assert_eq!(online(None), Ok(true));
// with timeout
let timeout = Duration::new(6, 0);
assert_eq!(online(Some(timeout)), Ok(true));
๐ If you want to help please take a look to this file.