commit 2df595704f6a090ad828a7e7c531d1437a396765
parent 3edcc2f1da9be27c36de1b3964305bb641747771
Author: Ashwini Patil <47225815+ashpatil-msft@users.noreply.github.com>
Date: Sat, 3 Jul 2021 12:48:34 -0700
Removing support for older rest schema versions (#1230)
Diffstat:
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/src/AppInstallerRepositoryCore/Rest/RestClient.cpp b/src/AppInstallerRepositoryCore/Rest/RestClient.cpp
@@ -18,7 +18,7 @@ using namespace AppInstaller::Utility;
namespace AppInstaller::Repository::Rest
{
// Supported versions
- std::set<Version> WingetSupportedContracts = { Version_0_2_0, Version_1_0_0 };
+ std::set<Version> WingetSupportedContracts = { Version_1_0_0 };
RestClient::RestClient(std::unique_ptr<Schema::IRestClient> supportedInterface, std::string sourceIdentifier)
: m_interface(std::move(supportedInterface)), m_sourceIdentifier(std::move(sourceIdentifier))
@@ -82,7 +82,7 @@ namespace AppInstaller::Repository::Rest
std::unique_ptr<Schema::IRestClient> RestClient::GetSupportedInterface(const std::string& api, const Version& version)
{
- if (version == Version_0_2_0 || version == Version_1_0_0)
+ if (version == Version_1_0_0)
{
return std::make_unique<Schema::V1_0::Interface>(api);
}
diff --git a/src/AppInstallerRepositoryCore/Rest/Schema/CommonRestConstants.h b/src/AppInstallerRepositoryCore/Rest/Schema/CommonRestConstants.h
@@ -6,6 +6,5 @@
namespace AppInstaller::Repository::Rest::Schema
{
// Winget supported contract versions
- const Utility::Version Version_0_2_0{ "0.2.0" }; // TODO: Remove once winget schema is finalized.
const Utility::Version Version_1_0_0{ "1.0.0" };
}