location manager was created on a dispatch queue

后端 未结 3 773
余生分开走
余生分开走 2021-01-02 05:45

what does this message mean?

NOTICE,A location manager (0xe86bdf0) was created on a dispatch queue executing on a thread other than the main thread. It is the devel

3条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-02 06:19

    With Swift 3, the following will ensure your function runs on main thread:

    OperationQueue.main.addOperation{"your location manager init code"}
    

提交回复
热议问题