Retrieving posts using angularJS