title: admin.database is not a function
body: <p>Iam using firebase admin but when I use exports like</p>
  
  <pre><code>var admin = require('firebase-admin');
  
  var serviceAccount = require('./firebaseconfig.json');
  
  admin.initializeApp({
   credential: admin.credential.cert(serviceAccount),
   databaseURL: "https://database.firebaseio.com"
  });
  
  module.exports = { admin : admin }
  </code></pre>
  
  <p>and used in another file by require like</p>
  
  <pre><code>var admin = require('../Firebaseconfig/firebase.js');
  console.log(admin.database())
  </code></pre>
  
  <p>then gives error while starting the server
  but if iam using admin.database() in the same file then Iam not getting any error.</p>
  
  <p>error snippet:</p>
  
  <ol>
  <li><p>console.log(admin.database())</p></li>
  <li><p>TypeError: admin.database is not a function
  at Object. </p></li>
  </ol>