From c82516985e9eaa38c6d13a1547611df189ae0531 Mon Sep 17 00:00:00 2001 From: Ionite Date: Tue, 8 Oct 2024 00:19:41 -0400 Subject: [PATCH] Fix Property attribute missing key value --- CHANGELOG.md | 4 ++++ Patreon.Api/Authorization/PatreonAuthHeaderHandler.cs | 3 ++- Patreon.Api/IPatreonApi.cs | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e1dceb..417ee3e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.0.0-pre.2] - 2024-10-08 +### Fixed +- Fixed IPatreonApi.GetIdentity missing Property attribute value error + ## [1.0.0-pre.1] - 2024-10-07 ### Added - Initial release. diff --git a/Patreon.Api/Authorization/PatreonAuthHeaderHandler.cs b/Patreon.Api/Authorization/PatreonAuthHeaderHandler.cs index e0ce7b8..df5e381 100644 --- a/Patreon.Api/Authorization/PatreonAuthHeaderHandler.cs +++ b/Patreon.Api/Authorization/PatreonAuthHeaderHandler.cs @@ -12,7 +12,8 @@ namespace Patreon.Api.Authorization; public class PatreonAuthHeaderHandler : DelegatingHandler { - private static HttpRequestOptionsKey AuthorizationTokensOptionsKey { get; } = new(); + private static HttpRequestOptionsKey AuthorizationTokensOptionsKey { get; } = + new(nameof(AuthorizationTokens)); private readonly ILogger logger; private readonly AsyncRetryPolicy policy; diff --git a/Patreon.Api/IPatreonApi.cs b/Patreon.Api/IPatreonApi.cs index eb7b570..ac1fd5e 100644 --- a/Patreon.Api/IPatreonApi.cs +++ b/Patreon.Api/IPatreonApi.cs @@ -18,7 +18,7 @@ Task GetToken( [Get("/oauth2/v2/identity")] Task GetIdentity( [Query] string include = "memberships.campaign,memberships.currently_entitled_tiers", - [Property] AuthorizationTokens? authorization = null, + [Property(nameof(AuthorizationTokens))] AuthorizationTokens? authorization = null, CancellationToken cancellationToken = default ); }