Fix 404 error handling

Currently panics when the image is not found (`err` object it's trying to return is `nil`).