angular-ui/bootstrap — pull request #2945 by ddomingues (2014-11-10 13:38:24+00:00)
Title: Autofocus corrects the second time that the modal is open

Autofocus corrects the second time that the modal is open. This fixes the issue #2802.
Example: http://plnkr.co/4sX9F3hObN0YmTU15m06