From 61fe1b1e8bb9292a8738e6ead53faca8bcd39692 Mon Sep 17 00:00:00 2001 From: RamsayLeung Date: Tue, 15 Feb 2022 10:00:44 +0800 Subject: [PATCH 1/2] Fix `avr` variant --- CHANGELOG.md | 1 + rspotify-model/src/enums/types.rs | 2 ++ 2 files changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5b39e754..374ddd3c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ ## 0.11.4 (unreleased) - ([#295](https://github.com/ramsayleung/rspotify/pull/295)) The `Tv` variant in `DeviceType` is actually case insensitive. +- ([#296](https://github.com/ramsayleung/rspotify/pull/296)) The `Avr` variant in `DeviceType` is actually case insensitive. ## 0.11.3 (2021.11.29) diff --git a/rspotify-model/src/enums/types.rs b/rspotify-model/src/enums/types.rs index 9716a73e..4d402622 100644 --- a/rspotify-model/src/enums/types.rs +++ b/rspotify-model/src/enums/types.rs @@ -99,6 +99,8 @@ pub enum DeviceType { /// 'Tv' and 'TV' as the type. #[serde(alias = "TV")] Tv, + /// Same as above, the Web API returns both 'AVR' and 'Avr' as the type. + #[serde(alias = "AVR")] Avr, Stb, AudioDongle, From 509bac1962aebcd5a4c91f77c7f2a07cf970b8fc Mon Sep 17 00:00:00 2001 From: RamsayLeung Date: Tue, 15 Feb 2022 11:12:52 +0800 Subject: [PATCH 2/2] Fix format error --- rspotify-model/src/enums/types.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rspotify-model/src/enums/types.rs b/rspotify-model/src/enums/types.rs index 4d402622..6838d9c0 100644 --- a/rspotify-model/src/enums/types.rs +++ b/rspotify-model/src/enums/types.rs @@ -99,7 +99,7 @@ pub enum DeviceType { /// 'Tv' and 'TV' as the type. #[serde(alias = "TV")] Tv, - /// Same as above, the Web API returns both 'AVR' and 'Avr' as the type. + /// Same as above, the Web API returns both 'AVR' and 'Avr' as the type. #[serde(alias = "AVR")] Avr, Stb,