Account confirmation now return name

This commit is contained in:
Unknown 2018-02-15 00:27:56 +01:00
parent 9dd946750d
commit 5eac91aada

View File

@ -68,7 +68,7 @@ public class UserManagerAPIController {
userRepository.save(user); userRepository.save(user);
pendingUserRepository.delete(pUser); pendingUserRepository.delete(pUser);
return new ResponseEntity<>(new UserConnectionData(true,user.getApiToken(),""),HttpStatus.OK); return new ResponseEntity<>(new UserConnectionData(true, user.getName(), user.getApiToken(),""),HttpStatus.OK);
} catch (TokenNotMatch tokenNotMatch) { } catch (TokenNotMatch tokenNotMatch) {
logger.warn("Pre token not match for "+data.id+"!"); logger.warn("Pre token not match for "+data.id+"!");
return new ResponseEntity<>(new UserConnectionData(false,"Token not match!","token"),HttpStatus.NOT_ACCEPTABLE); return new ResponseEntity<>(new UserConnectionData(false,"Token not match!","token"),HttpStatus.NOT_ACCEPTABLE);