switched std::optional to boost::optional

This commit is contained in:
fourtf
2019-08-25 22:58:19 +02:00
parent 84c7c40e86
commit 6cb82307e6
3 changed files with 145 additions and 3 deletions
+18
View File
@@ -9,6 +9,7 @@
#include "common/NetworkManager.hpp"
#include "singletons/Paths.hpp"
#include "singletons/Updates.hpp"
#include "util/CombinePath.hpp"
#include "widgets/dialogs/LastRunCrashDialog.hpp"
#ifdef USEWINSDK
@@ -113,6 +114,23 @@ void runGui(QApplication &a, Paths &paths, Settings &settings)
{
initQt();
auto thread = std::thread([dir = paths.miscDirectory] {
{
auto path = combinePath(dir, "Update.exe");
if (QFile::exists(path))
{
QFile::remove(path);
}
}
{
auto path = combinePath(dir, "update.zip");
if (QFile::exists(path))
{
QFile::remove(path);
}
}
});
chatterino::NetworkManager::init();
chatterino::Updates::getInstance().checkForUpdates();