Skip to content

Commit e6c08b2

Browse files
committed
Only find scripts once
1 parent 6b66fb3 commit e6c08b2

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

jquery.pjax.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -605,8 +605,7 @@ function extractContainer(data, xhr, options) {
605605
} else {
606606
var $head = $body = $(parseHTML(data))
607607
}
608-
obj.scripts = findAll($body, 'script[src]')
609-
findAll($body, 'script[src]').remove()
608+
obj.scripts = findAll($body, 'script[src]').remove()
610609

611610
// If response data is empty, return fast
612611
if ($body.length === 0)

0 commit comments

Comments
 (0)