title: 'A non-null String must be provided to a Text widget' (Flutter)
body: <p>I've tried to fix this with the following code but I'm afraid the error is still prevalent:</p>
  <pre><code>The following assertion was thrown building:
  A non-null String must be provided to a Text widget.
  'package:flutter/src/widgets/text.dart':
  Failed assertion: line 360 pos 10: 'data != null'
  </code></pre>
  <br>
  <pre><code>child: Row(
              children: [
                Text(
                    (contact.data()['rating'] == null)
                        ? &quot;n/a&quot;
                        : contact.data()['rating'].toString(),
                    style: TextStyle(
                        fontWeight: FontWeight.bold,
                        color: Colors.tealAccent)),
                Padding(
                  padding: const EdgeInsets.all(8.0),
                  child: CircleAvatar(
                    radius: 25,
                    backgroundImage: AssetImage(&quot;assets/girl2.jpg&quot;),
                  ),
                ),
                Spacer(),
                Text(
                  contact.data()['name'],
                  style: TextStyle(
                      fontWeight: FontWeight.w400, color: Colors.tealAccent),
                ),
                Spacer(),
                Text(
                  contact.data()['location'],
                  style: TextStyle(
                      letterSpacing: 1,
                      fontSize: 10,
                      fontWeight: FontWeight.w300,
                      color: Colors.tealAccent),
                ),
              ],
            ),
  </code></pre>
  <p>How would one go about solving this?</p>