title: How to query Firebase data after using .push() to add data?
body: <p>Here is the code for when I'm pushing the data to Firebase:</p>
  
  <pre><code>firebase.database().ref(`booklogs/${uid}/${book_id}`).push(page_id)
  
  booklogs : 
  {HUMjSHxVKAPfVXzOId9zCBkGOgv1:{
   book28917: {
   -KYp4FdYYODDZG1FX-Pb: 1
  }
  }
  }
  </code></pre>
  
  <p>My problem is when I query the data, the child node of the <code>${book_id}</code> includes the push key, but I only want to get the value which is <code>1</code> and not the push key.</p>
  
  <p>The code I use to query is: </p>
  
  <pre><code>var booklogs = db.ref(`booklogs/${uid}/${project}`); 
  
  booklogs.once('value')
    .then((snapshot) =&gt; {
      console.log(`pages viewed are  ${snapshot.key}: ${snapshot.val()}`);
      console.dir(snapshot.val());
    }).catch((error) =&gt; {
      console.log(`Error : ${error}`);
    });
  </code></pre>
  
  <p>The data returned in the console is:</p>
  
  <pre><code>pages viewed are  2634651: [object Object]                                                                            
  { '-KYp4FdYYODDZG1FX-Pb': 1 } 
  </code></pre>
  
  <p>Any input would be much appreciated. Thanks!</p>