File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11{
22 "id" : " Simplify" ,
3- "version" : " 2.14.2 " ,
3+ "version" : " 2.14.3 " ,
44 "title" : " Simplify" ,
55 "description" : " Library mod for CCLoader2." ,
66 "repository" : " https://github.com/CCDirectLink/CCLoader" ,
Original file line number Diff line number Diff line change 66 "prestart" : " prestart.js" ,
77 "plugin" : " plugin.js" ,
88 "hidden" : true ,
9- "version" : " 2.14.2 " ,
9+ "version" : " 2.14.3 " ,
1010 "ccmodDependencies" : {
1111 "ccloader" : " ^2.22.0" ,
1212 "crosscode" : " ^1.0.0"
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ import CustomDebugState from './lib/custom-debug-state.js';
2929 const baseDir = mod . baseDirectory . substr ( 7 ) ;
3030 const assets = window . simplify . getAssets ( mod ) ;
3131 for ( const asset of assets ) {
32- if ( asset . endsWith ( '.patch ' ) ) {
32+ if ( ! asset . endsWith ( '.json ' ) ) {
3333 continue ;
3434 }
3535
@@ -96,19 +96,7 @@ import CustomDebugState from './lib/custom-debug-state.js';
9696 * @returns {Promise<string> }
9797 */
9898 loadFile ( path , callback , errorCb ) {
99- const result = new Promise ( ( resolve , reject ) => {
100- path = this . _stripAssets ( path ) ;
101-
102- const req = new XMLHttpRequest ( ) ;
103- req . open ( 'GET' , path , true ) ;
104- req . onreadystatechange = function ( ) {
105- if ( req . readyState === 4 && req . status >= 200 && req . status < 300 ) {
106- resolve ( req . responseText ) ;
107- }
108- } ;
109- req . onerror = err => reject ( err ) ;
110- req . send ( ) ;
111- } ) ;
99+ const result = fetch ( this . _stripAssets ( path ) ) . then ( resp => resp . text ( ) ) ;
112100
113101 if ( callback || errorCb ) {
114102 result
You can’t perform that action at this time.
0 commit comments