Browse Source

removed some unnecessary code

juan 1 month ago
parent
commit
f77ebe0a09
1 changed files with 3 additions and 3 deletions
  1. 3 3
      lib/api_service.dart

+ 3 - 3
lib/api_service.dart

@@ -19,15 +19,15 @@ class ApiService {
       var url = Uri.http('127.0.0.1:3001', 'sorted_threads_by_date', {
         'folder': folder,
         'limit': '20',
-        'offset': pagenitaion,
+        'offset': pagenitaion.toString(),
       });
       var response = await http.get(url);
-      print(response);
+      // print(response);
       List<GetThreadResponse> allEmails = [];
 
       if (response.statusCode == 200) {
         List json = jsonDecode(response.body);
-        for (var item in json.take(1)) {
+        for (var item in json) {
           //each item in the json is a date
           if (item.length > 1 && item[0] is String && item[1] is List) {
             List<int> threadIDs = List<int>.from(item[1]);