c# EF Only return objects that have objects
<p>I'm using EF 6, have an Account that some have an relationship to a Setting object</p>

<p>However not all accounts have a setting object.
How can I return all Accounts that have a setting object?</p>

<pre><code> using (IUnitOfWork uw = _uwf.Create())
            {
 Dictionary&lt;string, Account&gt; accounts;
accounts = uw.Account.All.Where(ac=&gt;ac.Setting.IsEnabled).ToDictionary(a =&gt; a.Id, a =&gt; a); &lt;--- this is the problem, just want the ones that have a Setting otherwise im getting null reference thrown.
}
</code></pre>

<p>My Repository</p>

<pre><code>public class AccountRepository : MarkForDeleteRepository&lt;DomainObjects.Account&gt;, IAccountRepository
    {

        public override IEnumerable&lt;Account&gt; All
        {
            get
            {
                return
                    RepositorySet.Include("Country")
                        .Include("Setting")
            }
        }
</code></pre>