From 369b22f63a86c1c0f747042c3f85ae8b8cc624a2 Mon Sep 17 00:00:00 2001 From: Michael Malloy Date: Sat, 6 Feb 2021 16:31:44 -0600 Subject: [PATCH] Additional 404 check, remove unneeded "using"s --- Sharpii/NUSD.cs | 17 +++++++++++++++++ Sharpii/Program.cs | 3 --- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/Sharpii/NUSD.cs b/Sharpii/NUSD.cs index 55eb55b..52ba29f 100644 --- a/Sharpii/NUSD.cs +++ b/Sharpii/NUSD.cs @@ -320,6 +320,23 @@ namespace Sharpii } return; } + if (ex.Message == "The remote server returned an error: (404) Not Found.") + { + Console.WriteLine(""); + Console.WriteLine("The remote server returned a 404 error. Check your Title ID."); + Console.WriteLine(""); + Console.WriteLine("Error: SHARPII_NET_CORE_NUSD_REMOTE_404"); + Console.WriteLine(""); + if (OperatingSystem.Windows()) + { + Environment.Exit(0x00003E9E); + } + else + { + Environment.Exit(0x00000020); + } + return; + } if (ExceptionListRan == 0) { Console.WriteLine("An unknown error occured, please try again"); diff --git a/Sharpii/Program.cs b/Sharpii/Program.cs index 8c97f92..52bd7cb 100644 --- a/Sharpii/Program.cs +++ b/Sharpii/Program.cs @@ -18,9 +18,6 @@ using System; using System.IO; -using System.Net; -using libWiiSharp; -using System.Diagnostics; using System.Runtime.InteropServices; namespace Sharpii