mirror of
https://github.com/bloxstraplabs/bloxstrap.git
synced 2025-04-21 10:01:27 -07:00
Silently fail when making desktop shortcut (#410)
This commit is contained in:
parent
46e671e3ff
commit
cefe7cd22a
@ -454,7 +454,7 @@ namespace Bloxstrap
|
||||
|
||||
public static void CheckInstall()
|
||||
{
|
||||
App.Logger.WriteLine("[Bootstrapper::StartRoblox] Checking install");
|
||||
App.Logger.WriteLine("[Bootstrapper::CheckInstall] Checking install");
|
||||
|
||||
// check if launch uri is set to our bootstrapper
|
||||
// this doesn't go under register, so we check every launch
|
||||
@ -501,10 +501,18 @@ namespace Bloxstrap
|
||||
if (App.Settings.Prop.CreateDesktopIcon)
|
||||
{
|
||||
if (!File.Exists(DesktopShortcutLocation))
|
||||
{
|
||||
try
|
||||
{
|
||||
ShellLink.Shortcut.CreateShortcut(Directories.Application, "", Directories.Application, 0)
|
||||
.WriteToFile(DesktopShortcutLocation);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
App.Logger.WriteLine("[Bootstrapper::CheckInstall] Could not create desktop shortcut, aborting");
|
||||
App.Logger.WriteLine($"[Bootstrapper::CheckInstall] {ex}");
|
||||
}
|
||||
}
|
||||
|
||||
// one-time toggle, set it back to false
|
||||
App.Settings.Prop.CreateDesktopIcon = false;
|
||||
|
Loading…
Reference in New Issue
Block a user