Add extra read-only checks

This commit is contained in:
pizzaboxer 2023-07-30 23:35:43 +01:00
parent 894587554c
commit 1073357569
No known key found for this signature in database
GPG Key ID: 59D4A1DBAD0F2BA8
2 changed files with 3 additions and 0 deletions

View File

@ -164,6 +164,8 @@ namespace Bloxstrap
if (result != MessageBoxResult.Yes)
return;
Filesystem.AssertReadOnly(Paths.Application);
// yes, this is EXTREMELY hacky, but the updater process that launched the
// new version may still be open and so we have to wait for it to close
int attempts = 0;

View File

@ -40,6 +40,7 @@ namespace Bloxstrap.UI.ViewModels.Menu
{
Directory.CreateDirectory(Path.GetDirectoryName(Paths.CustomFont)!);
File.Copy(dialog.FileName, Paths.CustomFont);
Filesystem.AssertReadOnly(Paths.CustomFont);
}
}