mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Add improvements for chat feature
This commit is contained in:
parent
9ad7438d69
commit
9c3020fc77
@ -20,6 +20,7 @@ package org.wso2.carbon.device.mgt.core.metadata.mgt;
|
|||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
import org.wso2.carbon.base.MultitenantConstants;
|
||||||
import org.wso2.carbon.context.PrivilegedCarbonContext;
|
import org.wso2.carbon.context.PrivilegedCarbonContext;
|
||||||
import org.wso2.carbon.device.mgt.common.PaginationRequest;
|
import org.wso2.carbon.device.mgt.common.PaginationRequest;
|
||||||
import org.wso2.carbon.device.mgt.common.PaginationResult;
|
import org.wso2.carbon.device.mgt.common.PaginationResult;
|
||||||
@ -91,8 +92,12 @@ public class MetadataManagementServiceImpl implements MetadataManagementService
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
MetadataManagementDAOFactory.openConnection();
|
MetadataManagementDAOFactory.openConnection();
|
||||||
return metadataDAO.getMetadata(
|
if (metaKey.equals("EVALUATE_TENANTS")){
|
||||||
PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId(true), metaKey);
|
return metadataDAO.getMetadata(MultitenantConstants.SUPER_TENANT_ID, metaKey);
|
||||||
|
} else {
|
||||||
|
return metadataDAO.getMetadata(
|
||||||
|
PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId(true), metaKey);
|
||||||
|
}
|
||||||
} catch (MetadataManagementDAOException e) {
|
} catch (MetadataManagementDAOException e) {
|
||||||
String msg = "Error occurred while retrieving the metadata entry for metaKey:" + metaKey;
|
String msg = "Error occurred while retrieving the metadata entry for metaKey:" + metaKey;
|
||||||
log.error(msg, e);
|
log.error(msg, e);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user