@@ -14,7 +14,7 @@ public final class AudioSettings: @unchecked Sendable, Codable, JSONEncodable, H
1414 public init ( from decoder: Decoder ) throws {
1515 let container = try decoder. singleValueContainer ( )
1616 if let decodedValue = try ? container. decode ( String . self) ,
17- let value = Self ( rawValue: decodedValue) {
17+ let value = Self ( rawValue: decodedValue) {
1818 self = value
1919 } else {
2020 self = . unknown
@@ -24,6 +24,7 @@ public final class AudioSettings: @unchecked Sendable, Codable, JSONEncodable, H
2424
2525 public var accessRequestEnabled : Bool
2626 public var defaultDevice : DefaultDevice
27+ public var hifiAudioEnabled : Bool ?
2728 public var micDefaultOn : Bool
2829 public var noiseCancellation : NoiseCancellationSettingsRequest ?
2930 public var opusDtxEnabled : Bool
@@ -33,6 +34,7 @@ public final class AudioSettings: @unchecked Sendable, Codable, JSONEncodable, H
3334 public init (
3435 accessRequestEnabled: Bool ,
3536 defaultDevice: DefaultDevice ,
37+ hifiAudioEnabled: Bool ? = nil ,
3638 micDefaultOn: Bool ,
3739 noiseCancellation: NoiseCancellationSettingsRequest ? = nil ,
3840 opusDtxEnabled: Bool ,
@@ -41,16 +43,18 @@ public final class AudioSettings: @unchecked Sendable, Codable, JSONEncodable, H
4143 ) {
4244 self . accessRequestEnabled = accessRequestEnabled
4345 self . defaultDevice = defaultDevice
46+ self . hifiAudioEnabled = hifiAudioEnabled
4447 self . micDefaultOn = micDefaultOn
4548 self . noiseCancellation = noiseCancellation
4649 self . opusDtxEnabled = opusDtxEnabled
4750 self . redundantCodingEnabled = redundantCodingEnabled
4851 self . speakerDefaultOn = speakerDefaultOn
4952 }
50-
53+
5154 public enum CodingKeys : String , CodingKey , CaseIterable {
5255 case accessRequestEnabled = " access_request_enabled "
5356 case defaultDevice = " default_device "
57+ case hifiAudioEnabled = " hifi_audio_enabled "
5458 case micDefaultOn = " mic_default_on "
5559 case noiseCancellation = " noise_cancellation "
5660 case opusDtxEnabled = " opus_dtx_enabled "
@@ -60,17 +64,19 @@ public final class AudioSettings: @unchecked Sendable, Codable, JSONEncodable, H
6064
6165 public static func == ( lhs: AudioSettings , rhs: AudioSettings ) -> Bool {
6266 lhs. accessRequestEnabled == rhs. accessRequestEnabled &&
63- lhs. defaultDevice == rhs. defaultDevice &&
64- lhs. micDefaultOn == rhs. micDefaultOn &&
65- lhs. noiseCancellation == rhs. noiseCancellation &&
66- lhs. opusDtxEnabled == rhs. opusDtxEnabled &&
67- lhs. redundantCodingEnabled == rhs. redundantCodingEnabled &&
68- lhs. speakerDefaultOn == rhs. speakerDefaultOn
67+ lhs. defaultDevice == rhs. defaultDevice &&
68+ lhs. hifiAudioEnabled == rhs. hifiAudioEnabled &&
69+ lhs. micDefaultOn == rhs. micDefaultOn &&
70+ lhs. noiseCancellation == rhs. noiseCancellation &&
71+ lhs. opusDtxEnabled == rhs. opusDtxEnabled &&
72+ lhs. redundantCodingEnabled == rhs. redundantCodingEnabled &&
73+ lhs. speakerDefaultOn == rhs. speakerDefaultOn
6974 }
7075
7176 public func hash( into hasher: inout Hasher ) {
7277 hasher. combine ( accessRequestEnabled)
7378 hasher. combine ( defaultDevice)
79+ hasher. combine ( hifiAudioEnabled)
7480 hasher. combine ( micDefaultOn)
7581 hasher. combine ( noiseCancellation)
7682 hasher. combine ( opusDtxEnabled)
0 commit comments