mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Remove unnecessary usage of getAttributeNode(). Fixes #12072.
This commit is contained in:
parent
9d16fe6283
commit
3ef7a9683b
@ -485,8 +485,7 @@ function manipulationTarget( elem, content ) {
|
||||
|
||||
// Replace/restore the type attribute of script elements for safe DOM manipulation
|
||||
function disableScript( elem ) {
|
||||
var attr = elem.getAttributeNode("type");
|
||||
elem.type = ( attr && attr.specified ) + "/" + elem.type;
|
||||
elem.type = (elem.getAttribute("type") !== null) + "/" + elem.type;
|
||||
return elem;
|
||||
}
|
||||
function restoreScript( elem ) {
|
||||
|
Loading…
Reference in New Issue
Block a user