Replace $.parseJSON by JSON.parse
authorFomafix <fomafix@googlemail.com>
Tue, 22 Nov 2016 05:45:05 +0000 (06:45 +0100)
committerFomafix <fomafix@googlemail.com>
Wed, 23 Nov 2016 05:33:58 +0000 (05:33 +0000)
$.parseJSON gets deprecated in jQuery 3.0:
https://jquery.com/upgrade-guide/3.0/#deprecated-jquery-parsejson

Change-Id: I5d28e2cadd4bf598908943176a757b7c5386d27c

resources/src/mediawiki.special/mediawiki.special.apisandbox.js

index 217bd92..3b621be 100644 (file)
 
                                                $result.empty();
                                                if ( /^text\/mediawiki-api-prettyprint-wrapped(?:;|$)/.test( ct ) ) {
-                                                       data = $.parseJSON( data );
+                                                       data = JSON.parse( data );
                                                        if ( data.modules.length ) {
                                                                mw.loader.load( data.modules );
                                                        }