title: Condition must have static type of bool
body: <p>I am not able to use future bool here.. is there any way i can use future bool in this type of conditions..
  or is there any better way to do this?</p>
  <pre><code> Widget _buildRow(String pair) {
  
  
      final Future&lt;bool&gt; alreadySaved = DBHelper.getAllEmployees().then((value) =&gt; value.contains(pair));
      print(&quot;Already saved $alreadySaved&quot;);
      print(pair);
      return FutureBuilder(
        future: DBHelper.getAllEmployees(),
        builder: (context, AsyncSnapshot&lt;List&lt;FavrtTableModel&gt;&gt; snapshot) =&gt;
        snapshot.connectionState == ConnectionState.waiting ? Center(
          child: Icon(Icons.more_horiz),
        ):IconButton(
          icon: new  Icon(
            alreadySaved ? Icons.favorite : Icons.favorite_border,
            color:alreadySaved? Colors.red : Colors.white,
          ),onPressed: (){
          setState(() {
            if (alreadySaved) {
              _saved.remove(pair);
              _deleteEmployee(pair);
            } else {
              _saved.add(pair);
              _insert(pair);
  
  
            }
          });
        },
        ),
      );
    }
  </code></pre>