diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/services/impl/DeviceManagementAdminServiceImpl.java b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/services/impl/DeviceManagementAdminServiceImpl.java index 2ed0a554a..9cccf1699 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/services/impl/DeviceManagementAdminServiceImpl.java +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/services/impl/DeviceManagementAdminServiceImpl.java @@ -531,18 +531,6 @@ public class DeviceManagementAdminServiceImpl implements DeviceManagementAdminSe throw new BadRequestException( new ErrorResponse.ErrorResponseBuilder().setCode(400l).setMessage(errorMessage).build()); } - String scheduledTime = applicationInstallationBeanWrapper.getOperation().getSchedule(); - if (scheduledTime != null && !scheduledTime.isEmpty()) { - SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ"); - try { - String formattedScheduledDate = format.format(format.parse(scheduledTime)); - applicationInstallationBeanWrapper.getOperation().setSchedule(formattedScheduledDate); - } catch (ParseException e) { - String errorMessage = "Invalid date string is provided in for schedule parameter"; - throw new BadRequestException( - new ErrorResponse.ErrorResponseBuilder().setCode(400l).setMessage(errorMessage).build()); - } - } ApplicationInstallation applicationInstallation = applicationInstallationBeanWrapper.getOperation(); validateApplicationUrl(applicationInstallation.getUrl()); @@ -593,18 +581,6 @@ public class DeviceManagementAdminServiceImpl implements DeviceManagementAdminSe throw new BadRequestException( new ErrorResponse.ErrorResponseBuilder().setCode(400l).setMessage(errorMessage).build()); } - String scheduledTime = applicationUpdateBeanWrapper.getOperation().getSchedule(); - if (scheduledTime != null && !scheduledTime.isEmpty()) { - SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ"); - try { - String formattedScheduledDate = format.format(format.parse(scheduledTime)); - applicationUpdateBeanWrapper.getOperation().setSchedule(formattedScheduledDate); - } catch (ParseException e) { - String errorMessage = "Invalid date string is provided in for schedule parameter"; - throw new BadRequestException( - new ErrorResponse.ErrorResponseBuilder().setCode(400l).setMessage(errorMessage).build()); - } - } ApplicationUpdate applicationUpdate = applicationUpdateBeanWrapper.getOperation(); validateApplicationUrl(applicationUpdate.getUrl()); validateApplicationType(applicationUpdate.getType());