首页IT科技uncaught (in promise) object(Uncaught (in promise) TypeError: Cannot read properties of undefined (reading ‘result‘))

uncaught (in promise) object(Uncaught (in promise) TypeError: Cannot read properties of undefined (reading ‘result‘))

时间2025-09-18 18:28:27分类IT科技浏览5909
导读:Uncaught (in promise TypeError: Cannot read properties of undefined (reading result ...

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading result)

        如题所示问题                ,耽误三天寻找bug                        ,终于在我睡意朦胧之际发现了一道光        ,发现 await 出现的三个点:

        于是打开 findAllCategory()这个函数 对应的js文件:发现

        没错        ,问题就在 promise 函数                        ,没有返回值                ,自然后面就没有res啦        ,而且这里提示了 await 对次表达式没有影响                        ,就应该判断出 findAllCategory() 此函数是不是没有返回Promise对象                。

        总之                ,小心使得万年船,大意失荆州                        。成败在于细节!!!与君共勉吧!!!

创心域SEO版权声明:以上内容作者已申请原创保护,未经允许不得转载,侵权必究!授权事宜、对本内容有异议或投诉,敬请联系网站管理员,我们将尽快回复您,谢谢合作!

展开全文READ MORE
seo快速优化排名(掌握SEO利器:SEO快速优化软件带你飞) win10如何清除使用痕迹软件(Windows 10如何清除系统使用记录)