From 61463cc9e7d1cfdcb457c99dddfbac7e40b5fd5a Mon Sep 17 00:00:00 2001 From: Diavolo Date: Thu, 21 Jul 2022 21:30:44 +0200 Subject: [PATCH 1/2] [News] Update urls --- src/Components/Modules/News.cpp | 3 +-- src/Utils/Cache.cpp | 8 +------- src/Utils/Utils.cpp | 2 +- 3 files changed, 3 insertions(+), 10 deletions(-) diff --git a/src/Components/Modules/News.cpp b/src/Components/Modules/News.cpp index 24d0f29d..47bbab52 100644 --- a/src/Components/Modules/News.cpp +++ b/src/Components/Modules/News.cpp @@ -59,8 +59,7 @@ namespace Components UIScript::Add("visitWiki", [](UIScript::Token) { - //Utils::OpenUrl(Utils::Cache::GetStaticUrl("/wiki/")); - Utils::OpenUrl("https://github.com/Emosewaj/IW4x/wiki"); + Utils::OpenUrl(Utils::Cache::GetStaticUrl("/iw4x_faq")); }); UIScript::Add("visitDiscord", [](UIScript::Token) diff --git a/src/Utils/Cache.cpp b/src/Utils/Cache.cpp index cd761d76..f2e7a6f4 100644 --- a/src/Utils/Cache.cpp +++ b/src/Utils/Cache.cpp @@ -6,14 +6,8 @@ namespace Utils { "https://xlabs.dev", "https://raw.githubusercontent.com/XLabsProject/iw4x-client" - - //Links to old onion site - deprecated - //"https://iw4xcachep26muba.tor2web.xyz", - //"https://iw4xcachep26muba.onion.ws", - //"https://iw4xcachep26muba.onion.sh", - //"https://iw4xcachep26muba.onion.pet", - }; + std::string Cache::ValidUrl; std::mutex Cache::CacheMutex; diff --git a/src/Utils/Utils.cpp b/src/Utils/Utils.cpp index a214c963..6d9cd4df 100644 --- a/src/Utils/Utils.cpp +++ b/src/Utils/Utils.cpp @@ -123,7 +123,7 @@ namespace Utils void SafeShellExecute(HWND hwnd, LPCSTR lpOperation, LPCSTR lpFile, LPCSTR lpParameters, LPCSTR lpDirectory, INT nShowCmd) { - [=]() + [=] { __try { From 48c35efedca2dcea5f0ef9e51ff468a085d10878 Mon Sep 17 00:00:00 2001 From: Diavolo Date: Thu, 21 Jul 2022 21:41:32 +0200 Subject: [PATCH 2/2] [News] Remove unused urls --- src/Components/Modules/News.cpp | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/Components/Modules/News.cpp b/src/Components/Modules/News.cpp index 47bbab52..8a75adf8 100644 --- a/src/Components/Modules/News.cpp +++ b/src/Components/Modules/News.cpp @@ -57,16 +57,6 @@ namespace Components Utils::OpenUrl(Utils::Cache::GetStaticUrl("")); }); - UIScript::Add("visitWiki", [](UIScript::Token) - { - Utils::OpenUrl(Utils::Cache::GetStaticUrl("/iw4x_faq")); - }); - - UIScript::Add("visitDiscord", [](UIScript::Token) - { - Utils::OpenUrl("https://discord.gg/sKeVmR3"); - }); - Localization::Set("MPUI_CHANGELOG_TEXT", "Loading..."); Localization::Set("MPUI_MOTD_TEXT", NEWS_MOTD_DEFAULT);