title: Angularfire2 validate username before creating user
body: <p>I can't get my head around how queries works in AngularFirestore.</p>
  
  <p>I'm trying to validate a custom username against the users I already have in the database since I don't want users to be able to select the same username. Unfortunately, I fail already here. I'm using this piece of code based on what I have been able to read here and other places.</p>
  
  <pre><code> this.users = this.db.collection('/users', ref =&gt; ref.where('team', '==', this.user.team));
  </code></pre>
  
  <p>I'm sorry for being lost and asking what you might consider a basic question. I just can't get my head around why it's not working.</p>
  
  <p>Regards,</p>
  
  <p>Hendrik</p>