Skip to content

Commit

Permalink
Merge pull request #2 from RedGreenBlue09/crashfix
Browse files Browse the repository at this point in the history
Fix crash in WLANCare task
  • Loading branch information
gus33000 authored Oct 5, 2023
2 parents 3a1a90e + b2d4f91 commit c3c42bd
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions GetLumiaBSP/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -403,23 +403,23 @@ public static void WlanCare()
{
foreach (string? itm in wlan8974)
{
WlanFile = itm.Split('\\').Last();
WlanFile = itm;
}
}

if (wlan8626 != null)
{
foreach (string? itm in wlan8626)
{
WlanFile = itm.Split('\\').Last();
WlanFile = itm;
}
}

if (wlandat != null)
{
foreach (string? itm in wlandat)
{
WlanDatFile = itm.Split('\\').Last();
WlanDatFile = itm;
}
}
}
Expand All @@ -444,6 +444,8 @@ public static void WlanCare()
Directory.Delete(dir, true);
}
}
WlanFile = WlanFile.Split('\\').Last();
WlanDatFile = WlanDatFile.Split('\\').Last();

if (!string.IsNullOrEmpty(WlanFile) && !string.IsNullOrEmpty(WlanDatFile))
{
Expand Down

0 comments on commit c3c42bd

Please sign in to comment.