-
hello I'm not sure if this is a problem caused by using TCA incorrectly, but it's very strange that the Delegate is not called logically. This is where the reducer is first called
And let me show you the Reducer code.
To show you the internals of @dependency(.userLocationUsecase) private var userLocationUsecase in this code,
Finally, the code for the UserLocationUsecaseImplement
I put in a lot of MainActors because earlier discussions(#1743) indicated that the creation of the CLLocationManager should happen in the MainThread. What did I miss? I'd love to hear your thoughts |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I found what the problem was: I had marked |
Beta Was this translation helpful? Give feedback.
I found what the problem was: I had marked
public override init()
in the main actor annotation, but it wasn't actually running on the main thread. So I initialised the CLLocationManager in a lazy var and annotated the lazy var with the MainActor annotation.