always copy to the installer path

This commit is contained in:
bluepilledgreat 2025-04-05 19:27:17 +01:00
parent ab8eb3cef3
commit 1f59d29994

View File

@ -168,13 +168,11 @@ namespace Bloxstrap
App.Terminate(ErrorCode.ERROR_CANCELLED);
}
private void HandlePrivateChannelLaunch()
private void CopyBloxstrapToRobloxLocation()
{
const string LOG_IDENT = "Bootstrapper::HandlePrivateChannelLaunch";
const string LOG_IDENT = "Bootstrapper::CopyBloxstrapToRobloxLocation";
string path = Path.Combine(_latestVersionDirectory, AppData.RobloxInstallerExecutableName);
if (Deployment.PrivateChannel)
{
if (File.Exists(path))
{
string versionCopyHash = MD5Hash.FromFile(path);
@ -194,15 +192,6 @@ namespace Bloxstrap
File.Copy(Paths.Process, path);
}
}
else
{
if (File.Exists(path))
{
App.Logger.WriteLine(LOG_IDENT, $"Deleting {AppData.RobloxInstallerExecutableName} from the version directory");
File.Delete(path);
}
}
}
public async Task Run()
{
@ -320,7 +309,7 @@ namespace Bloxstrap
allModificationsApplied = await ApplyModifications();
}
HandlePrivateChannelLaunch();
CopyBloxstrapToRobloxLocation();
// check registry entries for every launch, just in case the stock bootstrapper changes it back