The lines that assign existing[0].outerHtml throw an exception when the DOM element gets removed in IE7 and IE8.
This is particularly and issue when user interactions cause the shape to be redrawn continuously, and when the set of elements get re-rendered regularly (eg. by using jQuery's render facility). Wrapping the lines containing existing[0].outerHtml in try-catch clauses restores the desired behaviour.
The lines that assign existing[0].outerHtml throw an exception when the DOM element gets removed in IE7 and IE8.
This is particularly and issue when user interactions cause the shape to be redrawn continuously, and when the set of elements get re-rendered regularly (eg. by using jQuery's render facility). Wrapping the lines containing existing[0].outerHtml in try-catch clauses restores the desired behaviour.