Skip to content
This repository was archived by the owner on Sep 11, 2023. It is now read-only.

Commit f58e618

Browse files
committed
Minor changes
1 parent 7677a21 commit f58e618

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

Interop/Updater/UpdateCheck.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ private static bool IsUpToDate(Version currentVer, Version latestVer)
6363

6464
private static async Task<Release> GetLatest()
6565
{
66-
var client = new GitHubClient(new ProductHeaderValue("spedit-client"));
66+
var client = new GitHubClient(new ProductHeaderValue("spcode-client"));
6767
var releases = await client.Repository.Release.GetAll("Hexer10", "Spcode");
6868
return releases[0];
6969
}

Program.cs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
using System.Runtime;
88
using System.Text;
99
using System.Threading;
10+
using System.Threading.Tasks;
1011
using System.Windows;
1112
using System.Windows.Media;
1213
using DiscordRPC;
@@ -29,7 +30,7 @@ public static class Program
2930
public static Timestamps discordTime = Timestamps.Now;
3031

3132
[STAThread]
32-
public static void Main(string[] args)
33+
public static async Task Main(string[] args)
3334
{
3435
// Init Discord RPC
3536
discordClient.Initialize();
@@ -110,7 +111,7 @@ public static void Main(string[] args)
110111
}
111112
catch (Exception e)
112113
{
113-
File.WriteAllText("CRASH_" + Environment.TickCount.ToString() + ".txt", BuildExceptionString(e, "SPEDIT LOADING"));
114+
File.WriteAllText("CRASH_" + Environment.TickCount.ToString() + ".txt", BuildExceptionString(e, "SPCODE LOADING"));
114115
MessageBox.Show("An error occured while loading." + Environment.NewLine + "A crash report was written in the editor-directory.",
115116
"Error while Loading",
116117
MessageBoxButton.OK,
@@ -124,9 +125,7 @@ public static void Main(string[] args)
124125
{
125126
if (OptionsObject.Program_CheckForUpdates)
126127
{
127-
#pragma warning disable 4014
128-
UpdateCheck.Check();
129-
#pragma warning restore 4014
128+
await UpdateCheck.Check();
130129
}
131130
#endif
132131
app.Startup += App_Startup;
@@ -136,7 +135,7 @@ public static void Main(string[] args)
136135
}
137136
catch (Exception e)
138137
{
139-
File.WriteAllText("CRASH_" + Environment.TickCount.ToString() + ".txt", BuildExceptionString(e, "SPEDIT MAIN"));
138+
File.WriteAllText("CRASH_" + Environment.TickCount.ToString() + ".txt", BuildExceptionString(e, "SPCODE MAIN"));
140139
MessageBox.Show("An error occured." + Environment.NewLine + "A crash report was written in the editor-directory.",
141140
"Error",
142141
MessageBoxButton.OK,

UpdaterTest/Program.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ internal static class Program
1616
public static async Task Main(string[] args)
1717
{
1818
var lat = await GetLatest();
19-
var release = lat.Assets.First(e => e.Name == "SPEdit.Portable.zip");
19+
var release = lat.Assets.First(e => e.Name == "SPCOde.Portable.zip");
2020
Console.WriteLine(release.Id);
2121
Console.WriteLine(release.Label);
2222
Console.WriteLine(release.Name);
@@ -28,7 +28,7 @@ private static async Task Check()
2828
try
2929
{
3030
var latestVer = await GetLatest();
31-
var release = latestVer.Assets.First(e => e.Name == "SPEdit.Portable.zip");
31+
var release = latestVer.Assets.First(e => e.Name == "SPCode.Portable.zip");
3232
Console.WriteLine(release.BrowserDownloadUrl);
3333

3434
using (var client = new WebClient())
@@ -79,7 +79,7 @@ private static bool IsUpToDate(string current, string latest)
7979

8080
private static async Task<Release> GetLatest()
8181
{
82-
var client = new GitHubClient(new ProductHeaderValue("spedit-client"));
82+
var client = new GitHubClient(new ProductHeaderValue("spcode-client"));
8383
var releases = await client.Repository.Release.GetAll("Hexer10", "Spcode");
8484
return releases[0];
8585
}

0 commit comments

Comments
 (0)