{"action":"created","issue":{"url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/428","repository_url":"https://api.github.com/repos/ga-wdi-exercises/project4","labels_url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/428/labels{/name}","comments_url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/428/comments","events_url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/428/events","html_url":"https://github.com/ga-wdi-exercises/project4/issues/428","id":197205886,"number":428,"title":"Issue with Factory/HTTP request/Controller Function??","user":{"login":"donovanallen","id":22160743,"avatar_url":"https://avatars.githubusercontent.com/u/22160743?v=3","gravatar_id":"","url":"https://api.github.com/users/donovanallen","html_url":"https://github.com/donovanallen","followers_url":"https://api.github.com/users/donovanallen/followers","following_url":"https://api.github.com/users/donovanallen/following{/other_user}","gists_url":"https://api.github.com/users/donovanallen/gists{/gist_id}","starred_url":"https://api.github.com/users/donovanallen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/donovanallen/subscriptions","organizations_url":"https://api.github.com/users/donovanallen/orgs","repos_url":"https://api.github.com/users/donovanallen/repos","events_url":"https://api.github.com/users/donovanallen/events{/privacy}","received_events_url":"https://api.github.com/users/donovanallen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":17,"created_at":"2016-12-22T15:59:13Z","updated_at":"2016-12-22T21:01:48Z","closed_at":null,"body":"I am trying to render data from my express app in an angular `showControllerFunction` via a Factory (`TunesFactory`). I chained two API calls in my create function on the index: \r\n\r\n```\r\nthis.create = function(user) {\r\n      $http({\r\n        url: \"http://localhost:4000/api/trip\",\r\n        method: \"post\",\r\n        data: user\r\n      }).then((res) => {\r\n        var mapdata = res.data\r\n        $http({\r\n          url: \"http://localhost:4000/api/trip/tunes\",\r\n          method: \"post\",\r\n          data: user\r\n        })\r\n        $state.go(\"show\", {}, {reload: true})\r\n        TripService.newtrip(mapdata)\r\n\r\n      })\r\n    }\r\n```\r\n\r\nwhich works as I can successfully console log both responses. In my `showControllerFunction`, I have: \r\n\r\n```\r\nfunction showControllerFunction($scope, TripFactory, TunesFactory, $state, $stateParams, TripService) {\r\n    this.trips = tripData\r\n\r\n    $scope.trip = TripFactory.get();\r\n\r\n    this.trip = TripService.getTrip();\r\n\r\n    $scope.tunes = TunesFactory.get();\r\n  };\r\n```\r\n\r\nMy tripFactory and service both work fine as I can successfully render `vm.trip.example` on the show page, but when I try to render `$scope.tunes` on the show page as:\r\n\r\n```\r\n    <div data-ng-repeat=\"tune in vm.tunes\">\r\n        <p>{{tune.name}}</p>\r\n      </div>\r\n```\r\n\r\nI get the following error in the console:\r\n![screen shot 2016-12-22 at 10 52 42 am](https://cloud.githubusercontent.com/assets/22160743/21431346/dba2ad62-c834-11e6-9b4c-d62c33c81f19.png)\r\n\r\nI don't even have any get requests to that route referenced anywhere in my code. "},"comment":{"url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/comments/268889747","html_url":"https://github.com/ga-wdi-exercises/project4/issues/428#issuecomment-268889747","issue_url":"https://api.github.com/repos/ga-wdi-exercises/project4/issues/428","id":268889747,"user":{"login":"superbuggy","id":17716232,"avatar_url":"https://avatars.githubusercontent.com/u/17716232?v=3","gravatar_id":"","url":"https://api.github.com/users/superbuggy","html_url":"https://github.com/superbuggy","followers_url":"https://api.github.com/users/superbuggy/followers","following_url":"https://api.github.com/users/superbuggy/following{/other_user}","gists_url":"https://api.github.com/users/superbuggy/gists{/gist_id}","starred_url":"https://api.github.com/users/superbuggy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/superbuggy/subscriptions","organizations_url":"https://api.github.com/users/superbuggy/orgs","repos_url":"https://api.github.com/users/superbuggy/repos","events_url":"https://api.github.com/users/superbuggy/events{/privacy}","received_events_url":"https://api.github.com/users/superbuggy/received_events","type":"User","site_admin":false},"created_at":"2016-12-22T21:01:48Z","updated_at":"2016-12-22T21:01:48Z","body":"which page isn't it showing up on?"}}
{"actor":{"display_login":"superbuggy"}}