Skip to content

Commit 166be93

Browse files
committed
Add workaround for available(watchOS, unavailable) being ignored
1 parent 84adb36 commit 166be93

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

FirebaseAI/Sources/Types/Internal/Live/BidiGenerateContentServerMessage.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import Foundation
1616

1717
/// Response message for BidiGenerateContent RPC call.
18-
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, *)
18+
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, watchOS 8.0, *)
1919
@available(watchOS, unavailable)
2020
struct BidiGenerateContentServerMessage: Sendable {
2121
/// The type of the message.
@@ -48,7 +48,7 @@ struct BidiGenerateContentServerMessage: Sendable {
4848

4949
// MARK: - Decodable
5050

51-
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, *)
51+
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, watchOS 8.0, *)
5252
@available(watchOS, unavailable)
5353
extension BidiGenerateContentServerMessage: Decodable {
5454
enum CodingKeys: String, CodingKey {

FirebaseAI/Sources/Types/Internal/Live/LiveSessionService.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import Foundation
2828
///
2929
/// This mainly comes into play when we don't want to block developers from sending messages while a
3030
/// session is being reloaded.
31-
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, *)
31+
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, watchOS 8.0, *)
3232
@available(watchOS, unavailable)
3333
actor LiveSessionService {
3434
let responses: AsyncThrowingStream<LiveServerMessage, Error>

FirebaseAI/Sources/Types/Public/Live/LiveServerToolCall.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
///
1717
/// The client should return matching ``FunctionResponsePart``, where the `functionId` fields
1818
/// correspond to individual ``FunctionCallPart``s.
19-
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, *)
19+
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, watchOS 8.0, *)
2020
@available(watchOS, unavailable)
2121
public struct LiveServerToolCall: Sendable {
2222
let serverToolCall: BidiGenerateContentToolCall

FirebaseAI/Sources/Types/Public/Live/LiveSession.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import Foundation
2121
/// through the incremental API (such as ``sendContent(_:turnComplete:)``).
2222
///
2323
/// To create an instance of this class, see ``LiveGenerativeModel``.
24-
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, *)
24+
@available(iOS 15.0, macOS 12.0, macCatalyst 15.0, tvOS 15.0, watchOS 8.0, *)
2525
@available(watchOS, unavailable)
2626
public final class LiveSession: Sendable {
2727
private let service: LiveSessionService

0 commit comments

Comments
 (0)