refactor profileService
This commit is contained in:
parent
7781b93a88
commit
4865ea8ad8
9 changed files with 241 additions and 204 deletions
|
|
@ -10,8 +10,6 @@ angular.module('copayApp.controllers').controller('disclaimerController',
|
|||
opts = opts || {};
|
||||
$log.debug('Creating profile');
|
||||
profileService.create(opts, function(err) {
|
||||
|
||||
console.log('[disclaimer.js.13]', err); //TODO
|
||||
if (err) {
|
||||
$log.warn(err);
|
||||
$scope.error = err;
|
||||
|
|
@ -33,8 +31,6 @@ angular.module('copayApp.controllers').controller('disclaimerController',
|
|||
|
||||
$scope.error = "";
|
||||
self.creatingProfile = false;
|
||||
|
||||
console.log('[disclaimer.js.33]'); //TODO
|
||||
});
|
||||
};
|
||||
|
||||
|
|
@ -44,10 +40,7 @@ angular.module('copayApp.controllers').controller('disclaimerController',
|
|||
|
||||
profileService.getProfile(function(err, profile) {
|
||||
if (!profile) {
|
||||
|
||||
console.log('[disclaimer.js.43]'); //TODO
|
||||
create(opts);
|
||||
console.log('[disclaimer.js.46]'); //TODO
|
||||
} else {
|
||||
$log.info('There is already a profile');
|
||||
self.creatingProfile = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue