diff --git a/src/icons/loader.js b/src/icons/loader.js index 5fb3fc529..6c89280d1 100644 --- a/src/icons/loader.js +++ b/src/icons/loader.js @@ -19,8 +19,8 @@ function getSprite(url) { resolve(xhr.responseText); } }; - xhr.onerror = function onSpriteError(err) { - reject(err); + xhr.onerror = function onSpriteError() { + reject(new Error(`Unexpected error when loading svg sprite. Status: ${xhr.status}`)); }; xhr.send(); }));