Commit 7a7cd53c1d8041800b7e06b79b94cb64560399c2

Authored by Caio Almeida
1 parent ca190d01

Fixing login to fit new API

Showing 1 changed file with 2 additions and 2 deletions   Show diff stats
www/js/controllers.js
... ... @@ -1250,7 +1250,7 @@ angular.module('confjuvapp.controllers', [])
1250 1250  
1251 1251 $http.get(ConfJuvAppUtils.pathTo(path))
1252 1252 .then(function(resp) {
1253   - $scope.profile = resp.data.user.person;
  1253 + $scope.profile = resp.data.person;
1254 1254 $scope.loginCallback(ConfJuvAppUtils.getPrivateToken());
1255 1255 $scope.setStateAndCityOfProfile();
1256 1256 $scope.loading = false;
... ... @@ -1358,7 +1358,7 @@ angular.module('confjuvapp.controllers', [])
1358 1358  
1359 1359 $http.post(ConfJuvAppUtils.pathTo('people/' + $scope.profile.id), jQuery.param(params), config)
1360 1360 .then(function(resp) {
1361   - $scope.profile = resp.data.user.person;
  1361 + $scope.profile = resp.data.person;
1362 1362 $scope.setStateAndCityOfProfile();
1363 1363 var popup = $ionicPopup.alert({ title: 'Perfil', template: 'Perfil atualizado com sucesso' });
1364 1364 popup.then(function() {
... ...