title: Flutter Error : [ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: type 'List<dynamic>' is not a subtype of type 'Map<String, dynamic>'
body: <p>i want to get list view from the api and put it into my app screen but it show me that</p>
  
  <pre><code>[ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: type 'List&lt;dynamic&gt;' is not a subtype of type 'Map&lt;String, dynamic&gt;'
  </code></pre>
  
  <p>in my provider i added the future which i need but it has an error now and i can't run login the app</p>
  
  <pre><code>List&lt;Country&gt; _country;
  List&lt;Country&gt; get country =&gt; _country;
  
  Future&lt;dynamic&gt; countryList() async {
      _isLoading = true;
      notifyListeners();
  
        http.Response  response = await http.get(Environment.country,
          headers: Environment.requestHeader);
  
      Map&lt;String,dynamic&gt; res = json.decode(response.body);
      var results;
      if (res['code'] == 200) {
        _country = [];
        res['message'].forEach((v) {
          _country.add(new Country.fromJson(v));
        });
        results = true;
      } else {
        results =
            FailedRequest(code: 400, message: res['message'], status: false);
      }
      _isLoading = false;
      notifyListeners();
      return results;
    }
  </code></pre>
  
  <p>and this is my model to class country which i use to return list</p>
  
  <pre><code>class Country{
    String name;
    String photo;
  
    Country({
      this.name,
      this.photo,
    });
  
    Country.fromJson(Map&lt;String, dynamic&gt; json){
      name = json['countryName'];
      photo = json['countryImage'].toString();
    }
  }
  </code></pre>
  
  <p>my json response </p>
  
  <pre><code>respond data : [{"countryName":"Egypt","countryImage":"https://i.ytimg.com/vi/TWaReNkjTLk/maxresdefault.jpg"},{"countryName":"Canada","countryImage":"https://pix10.agoda.net/geo/country/100/3_100_canada_02.jpg?s=1920x"},{"countryName":"US","countryImage":"https://www.green-card.com/assets/Uploads/living-usa-states-florida-green-card.jpg"}]
  </code></pre>
  
  <p>i tried to add to list statement but it didn't work also ! </p>