Skip to content

Commit 1984311

Browse files
v2.0.2
1 parent 7b88179 commit 1984311

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

EZCode/EZCode.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public class EzCode
2424
/// <summary>
2525
/// Directory of the script playing
2626
/// </summary>
27-
public static string Version { get; } = "2.0.1";
27+
public static string Version { get; } = "2.0.2";
2828
/// <summary>
2929
/// The Official EZCode Icon
3030
/// </summary>

EZCode/EZProj.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public class EZProj
5151
/// <summary>
5252
/// Icon for project
5353
/// </summary>
54-
public string IconPath { get; set; }
54+
public string? IconPath { get; set; }
5555
/// <summary>
5656
/// Icon for project
5757
/// </summary>
@@ -88,7 +88,7 @@ public EZProj(EzCode code, string _file = "")
8888
string file = "";
8989
if (parts.Length != 0)
9090
{
91-
string[] commas = string.Join(" ", parts.Skip(index)).Split(",").Select(x=>x.Trim()).ToArray();
91+
string[] commas = string.Join(" ", parts.Skip(index)).Split(",").Select(x => x.Trim()).ToArray();
9292
foreach (string comma in commas)
9393
{
9494
string before = comma.Split(":")[0];
@@ -186,7 +186,8 @@ public string ReadConvert(string? _filecontent = null)
186186
Debug = false;
187187
CloseOnEnd = true;
188188
Name ??= $"EZCode_v{EzCode.Version}";
189-
IconPath ??= Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "EZCode", "EZCode", "EZCode_Logo.ico");
189+
string iconpath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData), "EZCode", "EZCode", "EZCode_Logo.ico");
190+
IconPath ??= File.Exists(iconpath) ? iconpath : null;
190191

191192
string filecontent = FileContents;
192193
if (_filecontent != null) filecontent = _filecontent;

0 commit comments

Comments
 (0)