mirror of
https://github.com/openseadragon/openseadragon.git
synced 2025-01-31 23:21:42 +03:00
Declare _processDZIError directly on OpenSeadragon
This commit is contained in:
parent
9ef6e085c8
commit
c2107fcb22
@ -1814,7 +1814,7 @@ window.OpenSeadragon = window.OpenSeadragon || function( options ){
|
||||
} else if ( rootName == "Collection" ) {
|
||||
throw new Error( $.getString( "Errors.Dzc" ) );
|
||||
} else if ( rootName == "Error" ) {
|
||||
return processDZIError( root );
|
||||
return $._processDZIError( root );
|
||||
}
|
||||
|
||||
throw new Error( $.getString( "Errors.Dzi" ) );
|
||||
@ -1928,13 +1928,11 @@ window.OpenSeadragon = window.OpenSeadragon || function( options ){
|
||||
* @throws {Error}
|
||||
* @deprecated
|
||||
*/
|
||||
function processDZIError( errorNode ) {
|
||||
$._processDZIError = function ( errorNode ) {
|
||||
var messageNode = errorNode.getElementsByTagName( "Message" )[ 0 ],
|
||||
message = messageNode.firstChild.nodeValue;
|
||||
|
||||
throw new Error(message);
|
||||
}
|
||||
// Add an alias so this is in-scope for dzitilesource but obviously not a blessed public method:
|
||||
$._processDZIError = processDZIError;
|
||||
};
|
||||
|
||||
}( OpenSeadragon ));
|
||||
|
Loading…
x
Reference in New Issue
Block a user