Skip to content

Commit

Permalink
Remove check if modal contains an id on focus - it is not necessary
Browse files Browse the repository at this point in the history
Closes drublic#25
  • Loading branch information
drublic committed May 7, 2013
1 parent ee8c2fe commit 123ace0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## HEAD

* Remove check if modal contains an id on focus - it is not necessary (#25)
* Rename component.json to bower.json to match new bower spec

## 1.0.0 - 05.05.2013
Expand Down
4 changes: 1 addition & 3 deletions modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,7 @@

// Focus modal
modal.setFocus = function (hash) {
if (modal.activeElement &&
typeof modal.activeElement.contains === 'function' &&
!modal.activeElement.contains(hash)) {
if (modal.activeElement) {

// Set element with last focus
modal.lastActive = document.activeElement;
Expand Down

0 comments on commit 123ace0

Please sign in to comment.