mirror of
https://github.com/jquery/jquery.git
synced 2026-01-26 01:38:06 -05:00
Removed use of .trim() in globalEval, fixes #4036.
This commit is contained in:
@@ -627,9 +627,7 @@ jQuery.extend({
|
||||
|
||||
// Evalulates a script in a global context
|
||||
globalEval: function( data ) {
|
||||
data = jQuery.trim( data );
|
||||
|
||||
if ( data ) {
|
||||
if ( data && /\S/.test(data) ) {
|
||||
// Inspired by code by Andrea Giammarchi
|
||||
// http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html
|
||||
var head = document.getElementsByTagName("head")[0] || document.documentElement,
|
||||
|
||||
Reference in New Issue
Block a user