Merge "Make sure initialHash exists before checking its value"

This commit is contained in:
jenkins-bot 2014-10-27 03:25:10 +00:00 committed by Gerrit Code Review
commit 358268be7a

View file

@ -1066,7 +1066,7 @@ ve.dm.MWImageModel.prototype.attachScalable = function ( scalable ) {
// We have to adjust the details in the initial hash if the original
// image was 'default' since we didn't have default until now and the
// default dimensions that were 'recorded' were wrong
if ( this.initialHash.scalable.isDefault ) {
if ( !$.isEmptyObject( this.initialHash ) && this.initialHash.scalable.isDefault ) {
this.initialHash.scalable.currentDimensions = this.scalable.getDefaultDimensions();
}