ping results fix

fixed the way ping results are checked as it causes issues if a server
is offline and PHP notices are enabled