From 38dcc1a53e2049115e1c05f834bc4126938dfe5d Mon Sep 17 00:00:00 2001 From: Gravita <12893402+gravit0@users.noreply.github.com> Date: Thu, 26 Jun 2025 23:16:19 +0700 Subject: [PATCH] [FIX] Try fix create assets directory --- .../auth/profiles/LocalProfilesProvider.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/auth/profiles/LocalProfilesProvider.java b/LaunchServer/src/main/java/pro/gravit/launchserver/auth/profiles/LocalProfilesProvider.java index f0b83016..6883818f 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/auth/profiles/LocalProfilesProvider.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/auth/profiles/LocalProfilesProvider.java @@ -106,6 +106,15 @@ public CompletedProfile pushUpdate(UncompletedProfile profile, String tag, Clien LocalProfile localProfile = (LocalProfile) profile; localProfile = new LocalProfile(clientProfile, localProfile.clientDir, localProfile.assetDir); localProfile.profile = clientProfile; + if(flags.contains(UpdateFlag.USE_DEFAULT_ASSETS)) { + if(getUpdatesDir("assets") == null) { + Path assetDirPath = updatesDirPath.resolve("assets"); + if(!Files.exists(assetDirPath)) { + Files.createDirectories(assetDirPath); + } + updatesDirMap.put("assets", new HashedDir(assetDirPath, null, true, true)); + } + } if(assetActions != null && !assetActions.isEmpty()) { Path assetDir = updatesDirPath.resolve(clientProfile.getAssetDir()); execute(localProfile.assetDir, assetDir, assetActions);