gpt4 book ai didi

ios - swift 警告 : A lonng-running operation is being executed on the main thread

转载 作者:行者123 更新时间:2023-11-29 01:48:06 25 4
gpt4 key购买 nike

您好,请帮我解决这个问题!

我得到这个输出:

第一个输出是:仅(lldb)!

直到我按“继续程序执行”三次,然后我得到了这个:

Warning: A lonng-running operation is being executed on the main thread.

Break on WarnBlockingOperationOnMainThread() to debug.

fatal error: unexpectedly found nil while unwrapping an Optional value

(lldb)

我认为这段代码的问题是:

let predicate = NSPredicate(format: "username != '"+userName+"'")var query = PFQuery(className: "_User", predicate: predicate)var objects = query.findObjects()for object in objects {self.resualtprofilename.append(object["profileName"] as String)self.rtable.reloadData()}

请帮我解决这个问题!我讨厌(lldb)它总是困扰我,我不知道这是什么意思。

i'm using xcode 6.0 with Latest Parse SKD IOS

最佳答案

您需要更换的所有内容

findObjects

findObjectsInBackgroundWithBlock

不要忘记从解析中获取代码

关于ios - swift 警告 : A lonng-running operation is being executed on the main thread,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31687907/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com