当前位置:   article > 正文

Flutter-dio出错 [ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: type 'DioError' is n_flutter dioexceptiontype dioerror

flutter dioexceptiontype dioerror

[ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: type 'DioError' is not a subtype of type 'String'

 

下载文件出现上述错误:

Response response = await dio.download(
    "https://123.sogou.com/", "/storage/emulated/0/xx.html");
if (response.statusCode == 200) {
  print('下载请求成功');
}

是url路径写错了。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/小丑西瓜9/article/detail/657980
推荐阅读
相关标签
  

闽ICP备14008679号