Skip to content

Commit

Permalink
Added logs to CommonService for fusionAuth.
Browse files Browse the repository at this point in the history
  • Loading branch information
chinmoy12c committed Dec 4, 2023
1 parent 2a69acb commit dec9786
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,8 @@ public Mono<XMessage> apply(Pair<Boolean, String> result) {
from.setEncryptedDeviceID(deviceID);
xmsg.setFrom(from);
ClientResponse<UserResponse, Errors> response = botService.fusionAuthClient.retrieveUserByUsername(deviceID);
log.info("CommonService::UpdateUser: response.wasSuccessful: " + response.wasSuccessful());
log.info("CommonService::UpdateUser: isUserRegistered: " + isUserRegistered(response, appID));
if (response.wasSuccessful() && isUserRegistered(response, appID)) {
redisCacheService.setFAUserIDForAppCache(getFACacheName(deviceID, appID), response.successResponse.user.id.toString());
return Mono.just(xmsg);
Expand Down Expand Up @@ -384,7 +386,8 @@ private String getFAUserIdForApp(String deviceID, UUID appID) {

if (userID == null || userID.isEmpty()) {
ClientResponse<UserResponse, Errors> response = botService.fusionAuthClient.retrieveUserByUsername(deviceID);

log.info("CommonService::UpdateUser: response.wasSuccessful: " + response.wasSuccessful());
log.info("CommonService::UpdateUser: isUserRegistered: " + isUserRegistered(response, appID));
if (response.wasSuccessful() && isUserRegistered(response, appID)) {
userID = response.successResponse.user.id.toString();
redisCacheService.setFAUserIDForAppCache(getFACacheName(deviceID, appID), userID);
Expand Down

0 comments on commit dec9786

Please sign in to comment.