错误 Cannot read 属性 'split' of null in react-admin
error Cannot read property 'split' of null in react-admin
我在 => Connecting To A Real API 中收到此错误
“无法读取 null 的 属性 'split'”
请如何修复此错误
https://i.stack.imgur.com/zPES8.png
如果 header 不存在,它将(可能)return 为空。然后您尝试在其上执行 split
,但失败并给出错误。
尝试首先获取header,如果不为null,则拆分它。否则为 0.
我在 => Connecting To A Real API 中收到此错误 “无法读取 null 的 属性 'split'” 请如何修复此错误
https://i.stack.imgur.com/zPES8.png
如果 header 不存在,它将(可能)return 为空。然后您尝试在其上执行 split
,但失败并给出错误。
尝试首先获取header,如果不为null,则拆分它。否则为 0.