title: Can't access properties of my Javascript object
body: <p>I'm using Angular.js to fetch a single record from my API. I'm getting the record back as an object, I can log the object and see it's properties but I cannot access any of the properties. I just get <code>undefined</code>.</p>
  
  <pre><code>var template = Template.get({id: id});
  $scope.template = template;
  ...
  console.log(template); // displays object
  console.log(template.content); // undefined
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/N2AYw.png" alt="Screenshot of console.log(template);"></p>
  
  <p><strong>UPDATE</strong></p>
  
  <pre><code>var id = $routeParams.templateId;
  var template = Template.get({id: id});
  $scope.template = template;
  
  /*** Template placeholders ***/
  $scope.updatePlaceholders = function () {
      var placeholders = [];
      var content = template.content;
  
      console.log(template); // dumps the object in the screenshot
      console.log("content" in template); // displays false
  
      // get placeholders that match patter
      var match = content.match(/{([A-z0-9]+)}/gmi);
      ...
  }
  
  $scope.$on('$viewContentLoaded', function(){
      $scope.updatePlaceholders();
  });
  </code></pre>