You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: TACTSharp/CDN.cs
+22-19Lines changed: 22 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ public class CDN
16
16
17
17
// TODO: The implementation around this needs improving. For local installations, this comes from .build.info. For remote this is set by the first CDN server it retrieves.
18
18
// However, if ProductDirectory is accessed before the first CDN is loaded (or if not set through .build.info loading) it'll be null.
19
-
publicstringProductDirectory;
19
+
publicstringProductDirectory=string.Empty;
20
20
21
21
// TODO: Memory mapped cache file access?
22
22
publicCDN(Settingssettings)
@@ -26,23 +26,23 @@ public CDN(Settings settings)
26
26
27
27
publicvoidOpenLocal()
28
28
{
29
-
if(Settings.BaseDir!=null)
30
-
{
31
-
if(CASCIndexInstances.Count>0)
32
-
return;
29
+
if(string.IsNullOrEmpty(Settings.BaseDir))
30
+
return;
33
31
34
-
try
35
-
{
36
-
varlocalTimer=newStopwatch();
37
-
localTimer.Start();
38
-
LoadCASCIndices();
39
-
localTimer.Stop();
40
-
Console.WriteLine("Loaded local CASC indices in "+Math.Round(localTimer.Elapsed.TotalMilliseconds)+"ms");
41
-
}
42
-
catch(Exceptione)
43
-
{
44
-
Console.WriteLine("Failed to load CASC indices: "+e.Message);
45
-
}
32
+
if(CASCIndexInstances.Count>0)
33
+
return;
34
+
35
+
try
36
+
{
37
+
varlocalTimer=newStopwatch();
38
+
localTimer.Start();
39
+
LoadCASCIndices();
40
+
localTimer.Stop();
41
+
Console.WriteLine("Loaded local CASC indices in "+Math.Round(localTimer.Elapsed.TotalMilliseconds)+"ms");
42
+
}
43
+
catch(Exceptione)
44
+
{
45
+
Console.WriteLine("Failed to load CASC indices: "+e.Message);
0 commit comments