From 4aee621039621559c28f6103aaeef87fcc2a0525 Mon Sep 17 00:00:00 2001 From: Ace Date: Wed, 17 Oct 2018 20:30:17 +0530 Subject: [PATCH] Fixing tenanted username --- .../mgt/jaxrs/service/impl/GeoLocationBasedServiceImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GeoLocationBasedServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GeoLocationBasedServiceImpl.java index 854972b833d..fecf3ea6b4c 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GeoLocationBasedServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GeoLocationBasedServiceImpl.java @@ -96,9 +96,8 @@ public class GeoLocationBasedServiceImpl implements GeoLocationBasedService { sortByFields.add(sortByField); // this is the user who initiates the request - String authorizedUser = MultitenantUtils.getTenantAwareUsername( - CarbonContext.getThreadLocalCarbonContext().getUsername() + "@" + - CarbonContext.getThreadLocalCarbonContext().getTenantDomain()); + String authorizedUser = CarbonContext.getThreadLocalCarbonContext().getUsername() + "@" + + CarbonContext.getThreadLocalCarbonContext().getTenantDomain(); try { String tenantDomain = MultitenantUtils.getTenantDomain(authorizedUser);