angular/angular.js — pull request #1062 by vojtajina (2012-06-16 20:12:31+00:00)
Title: fix($location): url rewriting if element was removed

When user clicks a link, $location needs to intercept this event. The doesn't have to be target element of the DOM event, so it needs to traverse the DOM, to find first parent.

If the target element was removed from DOM, during the same event, it would throw an exception. This fixes the issue.

Closes #1058