Correct error handling for resources not found.
Prefer CDN delivery by default