ub3lal 1 ヶ月 前
コミット
abfec7ace3
1 ファイル変更6 行追加0 行削除
  1. 6 0
      lib/src/http_request.dart

+ 6 - 0
lib/src/http_request.dart

@@ -65,7 +65,13 @@ class HttpGetImage {
         response = await http
             .get(Uri.parse(url), headers: headers)
             .timeout(Duration(seconds: time));
+
         if (response.statusCode == 200) {
+          if (response.body.isNotEmpty) {
+            sendPort.send(null);
+            break;
+          }
+
           sendPort.send(response.bodyBytes);
           break;
         }