From 2723afc6617dfc4123631bc04157cae1dce2e724 Mon Sep 17 00:00:00 2001 From: Zach Date: Fri, 1 Nov 2024 17:49:35 -0600 Subject: [PATCH] Fix Xcode 16.1 error about property not on main actor (#119) * Fix error about property not on main actor * Attempt to fix Ubuntu CI * Update ubuntu.yml * Remove changes * Update ubuntu.yml --- .github/workflows/ubuntu.yml | 2 +- .../PropertyWrappers/Dependency/ObservedDependency.swift | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index ab88059..77d8983 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -14,7 +14,7 @@ jobs: steps: - uses: sersoft-gmbh/swifty-linux-action@v3 with: - release-version: 6.0 + release-version: 6.0.1 - uses: actions/checkout@v3 - name: Build for release run: swift build -v -c release diff --git a/Sources/AppState/PropertyWrappers/Dependency/ObservedDependency.swift b/Sources/AppState/PropertyWrappers/Dependency/ObservedDependency.swift index a4edb4d..d827941 100644 --- a/Sources/AppState/PropertyWrappers/Dependency/ObservedDependency.swift +++ b/Sources/AppState/PropertyWrappers/Dependency/ObservedDependency.swift @@ -2,6 +2,7 @@ import SwiftUI /// The `@ObservedDependency` property wrapper is a feature provided by AppState, intended to simplify dependency handling throughout your application. It makes it easy to access, share, and manage dependencies in a neat and Swift idiomatic way. It works the same as `@AppDependency`, but comes with the power of the `@ObservedObject` property wrapper. +@MainActor @propertyWrapper public struct ObservedDependency: DynamicProperty where Value: ObservableObject { /// Path for accessing `ObservedDependency` from Application. private let keyPath: KeyPath>