mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Fixed issue in Policy Task when DeviceAuthorization enabled.
This commit is contained in:
parent
1252d4c160
commit
a3e20367f2
@ -82,8 +82,13 @@ public class OperationManagerImpl implements OperationManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
List<DeviceIdentifier> authorizedDeviceList = DeviceManagementDataHolder.getInstance().
|
List<DeviceIdentifier> authorizedDeviceList;
|
||||||
getDeviceAccessAuthorizationService().isUserAuthorized(deviceIds).getAuthorizedDevices();
|
if (operation != null && PolicyOperation.POLICY_OPERATION_CODE.equals(operation.getCode())) {
|
||||||
|
authorizedDeviceList = deviceIds;
|
||||||
|
} else {
|
||||||
|
authorizedDeviceList = DeviceManagementDataHolder.getInstance().
|
||||||
|
getDeviceAccessAuthorizationService().isUserAuthorized(deviceIds).getAuthorizedDevices();
|
||||||
|
}
|
||||||
if (authorizedDeviceList.size() > 0) {
|
if (authorizedDeviceList.size() > 0) {
|
||||||
try {
|
try {
|
||||||
int tenantId = CarbonContext.getThreadLocalCarbonContext().getTenantId();
|
int tenantId = CarbonContext.getThreadLocalCarbonContext().getTenantId();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user