mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-18 23:33:12 +09:00
Change mod packs to datastore
This commit is contained in:
4 files changed
+20
-26
No files matched your search
@@ -218,7 +218,7 @@ async function uploadExport(req: Request, res: Response) {
|
||||
res.sendStatus(400);
|
||||
return;
|
||||
}
|
||||
let modPack = res.app.locals.controller.modPacks.get(modPackId);
|
||||
let modPack = res.app.locals.controller.modPacks.getCopy(modPackId);
|
||||
if (!modPack) {
|
||||
res.sendStatus(400);
|
||||
return;
|
||||
@@ -261,6 +261,7 @@ async function uploadExport(req: Request, res: Response) {
|
||||
|
||||
modPack.exportManifest = new lib.ExportManifest(assets);
|
||||
modPack.fillDefaultSettings(settingPrototypes, logger);
|
||||
res.app.locals.controller.modPacks.set(modPack.id, modPack);
|
||||
res.app.locals.controller.modPacksUpdated([modPack]);
|
||||
|
||||
res.sendStatus(200);
|
||||
|
||||
Reference in new issue
Block a user