Get rid of errors (selection can have size 0).
This was SVN commit r3061.
This commit is contained in:
parent
695d966788
commit
416c7fe4ba
@ -211,7 +211,7 @@ function resetUpdateVars()
|
||||
propertyWatches[watchedObject].unwatchAll( selectionWatchHandler ); // Remove the handler
|
||||
|
||||
propertyWatches = new Array();
|
||||
if( selection[0] )
|
||||
if( selection.length > 0 && selection[0] )
|
||||
{
|
||||
// Watch the object itself
|
||||
selection[0].watchAll( selectionWatchHandler );
|
||||
@ -228,7 +228,7 @@ function resetUpdateVars()
|
||||
}
|
||||
}
|
||||
selectionChanged = false;
|
||||
if( selection[0] )
|
||||
if( selection.length > 0 && selection[0] )
|
||||
{
|
||||
selectionTemplate = selection[0].template;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user