Fixed an issue with JSON data in packed scripts. (Bug #1298)
[jquery.git] / src / ajax / ajax.js
index 102c7f9..4fb63c0 100644 (file)
@@ -785,7 +785,7 @@ jQuery.extend({
 
                // Get the JavaScript object, if JSON is used.
                if ( type == "json" )
-                       eval( "data = " + data );
+                       data = eval("(" + data + ")");
 
                // evaluate scripts within html
                if ( type == "html" )