Skip to content

Commit ca4448a

Browse files
rwarnerclaude
andcommitted
Guard HALiveActivityConfiguration references in Widgets.swift
HALiveActivityConfiguration is iOS-only; wrap all three call sites with #if os(iOS) && !targetEnvironment(macCatalyst). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent c6a6133 commit ca4448a

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

Sources/Extensions/Widgets/Widgets.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,11 @@ struct WidgetsBundleLegacy: WidgetBundle {
2121
}
2222

2323
var body: some Widget {
24+
#if os(iOS) && !targetEnvironment(macCatalyst)
2425
if #available(iOSApplicationExtension 17.2, *) {
2526
HALiveActivityConfiguration()
2627
}
28+
#endif
2729
WidgetAssist()
2830
LegacyWidgetActions()
2931
WidgetOpenPage()
@@ -37,9 +39,11 @@ struct WidgetsBundle17: WidgetBundle {
3739
}
3840

3941
var body: some Widget {
42+
#if os(iOS) && !targetEnvironment(macCatalyst)
4043
if #available(iOSApplicationExtension 17.2, *) {
4144
HALiveActivityConfiguration()
4245
}
46+
#endif
4347
WidgetCommonlyUsedEntities()
4448
WidgetCustom()
4549
WidgetAssist()
@@ -60,7 +64,9 @@ struct WidgetsBundle18: WidgetBundle {
6064
}
6165

6266
var body: some Widget {
67+
#if os(iOS) && !targetEnvironment(macCatalyst)
6368
HALiveActivityConfiguration()
69+
#endif
6470

6571
// Controls
6672
ControlAssist()

0 commit comments

Comments
 (0)