Skip to content

Commit 66dd6bc

Browse files
committed
Merge pull request #374 from defunkt/safe-blur
IE fix for blurring of active element
2 parents 67fbdce + b6d028d commit 66dd6bc

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

jquery.pjax.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,9 @@ function pjax(options) {
263263
}
264264

265265
// Clear out any focused controls before inserting new page contents.
266-
document.activeElement.blur()
266+
try {
267+
document.activeElement.blur()
268+
} catch (e) { }
267269

268270
if (container.title) document.title = container.title
269271
context.html(container.contents)

0 commit comments

Comments
 (0)