Extract network exception detection into extension method.
Use better expected error classification.