mirror of
				https://github.com/smartfrigde/armcord.git
				synced 2024-08-14 23:56:58 +00:00 
			
		
		
		
	fix: modloader downloading
This commit is contained in:
		
							parent
							
								
									a49ae6b378
								
							
						
					
					
						commit
						871202aad1
					
				
					 3 changed files with 3 additions and 3 deletions
				
			
		|  | @ -3,8 +3,9 @@ import extract from "extract-zip"; | |||
| import path from "path"; | ||||
| import {getConfig} from "../../common/config"; | ||||
| import fs from "fs"; | ||||
| import {promisify} from "node:util"; | ||||
| import {pipeline} from "stream"; | ||||
| const streamPipeline = pipeline; | ||||
| const streamPipeline = promisify(pipeline); | ||||
| async function updateModBundle(): Promise<void> { | ||||
|     if ((await getConfig("noBundleUpdates")) == undefined ?? false) { | ||||
|         try { | ||||
|  | @ -108,7 +109,6 @@ export async function installModLoader(): Promise<void> { | |||
| 
 | ||||
|             break; | ||||
|         } | ||||
| 
 | ||||
|         await streamPipeline(loaderZip.body, fs.createWriteStream(zipPath)); | ||||
|         await extract(zipPath, {dir: path.join(app.getPath("userData"), "plugins")}); | ||||
| 
 | ||||
|  |  | |||
|  | @ -17,7 +17,7 @@ export function createSetupWindow(): void { | |||
|         webPreferences: { | ||||
|             sandbox: false, | ||||
|             spellcheck: false, | ||||
|             preload: path.join(import.meta.dirname, "preload.js") | ||||
|             preload: path.join(import.meta.dirname, "preload.mjs") | ||||
|         } | ||||
|     }); | ||||
|     ipcMain.on("saveSettings", (_event, args: Settings) => { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue