title: Flutter Firestore FutureBuilder filter with if statement
body: <p>I'm trying to filter a list of a FutureBuilder as follows:</p>
  
  <pre><code>return new FutureBuilder(
                      future: Firestore.instance
                          .collection('user')
                          .getDocuments(),
                      builder: (BuildContext context, AsyncSnapshot snapshot2) {
                        if (snapshot2.hasData) {
                          if (snapshot2.data != null) {
                            return new Column(
                              children: &lt;Widget&gt;[
                                new Expanded(
                                  child: new ListView(
                                    children: snapshot2.data.documents
                                        .map&lt;Widget&gt;((DocumentSnapshot document) {
                                          if(document['first_name'] == 'James') {
                                            return new FindFollowerWidget(
                                              name: document['first_name'] + " " + document['last_name'],
                                              username: document['username'],
                                            );
                                          }
                                    }).toList(),
                                  ),
                                ),
                              ],
                            );
                          }
                        }else {
                          return new CircularProgressIndicator();
                        }
                      });
  </code></pre>
  
  <p>This FutureBuilder works when I remove the if statement; however, when I include the following if statement it Flutter throws an error:</p>
  
  <pre><code>new ListView(
      children: snapshot2.data.documents.map&lt;Widget&gt;((DocumentSnapshot document) {
          if(document['first_name'] == 'James') {
              return new FindFollowerWidget(
                  name: document['first_name'] + " " + document['last_name'],
                  username: document['username'],
                  );
          }
      ).toList(),
   ),
  </code></pre>
  
  <p>My question: how can I only return the FindFollowerWidget when a document snapshot field has a specific value (in this case the first name being "James"? </p>
  
  <p>Thanks!  </p>