title: Firebase Cloud Functions Not Running
body: <p>I'm getting some unexpected behavior from <code>Firebase Cloud Functions</code> where it seems the function below does not run. My expectation is the data in the <code>/posts</code> endpoint will be logged to the console. I get no errors on deploying the function.</p>
  
  <p>The function is for a backend-only action that the client/user is not involved in, so a trigger based on database events or <code>https</code> wont work for me without setting up another server to call the endpoint. </p>
  
  <p>Is there any reason why the below would not log ?</p>
  
  <pre><code>const functions = require('firebase-functions');
  const admin = require('firebase-admin');
  admin.initializeApp(functions.config().firebase);
  
  
   getScheduledPosts = () =&gt; {
             admin.database().ref("/posts")
            .orderByKey()
            .once("value")
            .then( (snapshot) =&gt; {
                console.log(snapshot);
             })
             .catch(err =&gt; {console.log(err)});
            console.log("Posts Ran")
        }
  
    // Call this function 
    getScheduledPosts();
  </code></pre>