diff --git a/src/jquery.i18n.messagestore.js b/src/jquery.i18n.messagestore.js index ba81ce5..67a2885 100644 --- a/src/jquery.i18n.messagestore.js +++ b/src/jquery.i18n.messagestore.js @@ -27,13 +27,13 @@ .done( deferred.resolve ) .fail( function ( jqxhr, settings, exception ) { $.i18n.log( 'Error in loading messages from ' + url + ' Exception: ' + exception ); - // Ignore 404 exception, because we are handling fallabacks explicitly - deferred.resolve(); + // Ignore 404 exception, because we are handling fallbacks explicitly + if ( jqxhr.status === 404 ) { + deferred.resolve(); + } else { + deferred.reject( exception ); + } } ); - - return deferred.promise(); - } - /** * See https://github.com/wikimedia/jquery.i18n/wiki/Specification#wiki-Message_File_Loading */