title: How does $uid node works on firebase-realtime-database rules?
body: <p>I'm working on firebase-realtime-database on ionic, I am a bit confuse about how to "read" and "write" inside the $uid node. Which i am currently dealing with denied access.</p>
  
  <p>the node looks like this</p>
  
  <pre><code>rules {
  "info": {     
     "$uid": {
        ".read": true,
        ".write": "$uid === auth.uid"
     }     
   }
  }
  </code></pre>
  
  <p>while my json database looks like this</p>
  
  <pre><code>
  {
    info: {
       01: {
       name:jay
       age:16
       }
    }
  }
  
  
  </code></pre>
  
  <p>I am a bit confuse what steps to take in order to access the data inside the $uid node. I did try to update my json database node to this.</p>
  
  <pre><code>
  {
    info: {
      f3de4734-8fb2-42bd-971d-8e693f8aab3b: {  // auth.uid of dummy@gmail.com
              01: {
              name:jay
              age:16
              }
      }
    }
  }
  
  </code></pre>
  
  <p>and my "getafdData() function" path directory to "'info/'+ getuser".</p>
  
  <p>the above updates work only if the "getuser" is the owner of the file or the node that holds the data, however i want it to be read by other authenticated users as well which i can't understand with $uid.</p>
  
  <p>I have already Authenticate the login using "signInWithEmailAndPassword()" function by firebase</p>
  
  <p>this is the code i use to authenticate</p>
  
  <pre><code> try {
        var r = await this.fAuth.auth.signInWithEmailAndPassword(
          "dummy@gmail.com",
          "123456"
        );
        if (r) {
          console.log("Successfully logged in!");
          await this.getafdData(); \\\ get the data when login
  
        }
  
      } catch (err) {
        console.error(err);
      }
  </code></pre>
  
  <pre><code>async getafdData(){
  
  var firebaseRef = this.afd.database.ref();
  let data = await new Promise(function(resolve,reject){
     return firebaseRef.child('info/')
        .on("child_added", function(snapshot) {
           console.log(snapshot.val());
           //resolve(data);
  
  
         }, function(err) {
           console.log(err);
           reject(err);
         })
      }); 
  return data;
  }
  </code></pre>
  
  <p>Can you advise what i am doing wrong? or rather correct steps i should do in order to access the $uid node?</p>