From 3fa2e6ae8bfbf5d8f83b3ffcf24d7c090ce31c9e Mon Sep 17 00:00:00 2001 From: RadRussianRus Date: Sat, 17 Apr 2021 14:35:50 +0300 Subject: [PATCH] Use new updates.json Some notable changes: * Direct links. This will allow upload updates as release asset, which is faster. * Minify JSON on publish, pretty-printed JSON in repo. This will make work with JSON files easier, while users will still have minified versions. --- Telegram/SourceFiles/core/update_checker.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Telegram/SourceFiles/core/update_checker.cpp b/Telegram/SourceFiles/core/update_checker.cpp index 2ceb8e8e5..18c78b209 100644 --- a/Telegram/SourceFiles/core/update_checker.cpp +++ b/Telegram/SourceFiles/core/update_checker.cpp @@ -613,7 +613,7 @@ HttpChecker::HttpChecker(bool testing) : Checker(testing) { void HttpChecker::start() { const auto path = Local::readAutoupdatePrefix() - + qstr("/current"); + + qstr("/updates.json"); auto url = QUrl(path); DEBUG_LOG(("Update Info: requesting update state")); const auto request = QNetworkRequest(url); @@ -726,7 +726,7 @@ std::optional HttpChecker::parseResponse( return validateLatestUrl( bestAvailableVersion, bestIsAvailableAlpha, - Local::readAutoupdatePrefix() + bestLink); + bestLink); } QString HttpChecker::validateLatestUrl(