From ebe9842d9a7a3dda8c965c55c55708170bf05682 Mon Sep 17 00:00:00 2001 From: sandaru Date: Mon, 13 Sep 2021 14:18:29 +0530 Subject: [PATCH] Fix web-clip install issue --- .../device/mgt/core/util/MDMAndroidOperationUtil.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/util/MDMAndroidOperationUtil.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/util/MDMAndroidOperationUtil.java index 99cacfd950..a1e5210948 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/util/MDMAndroidOperationUtil.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/util/MDMAndroidOperationUtil.java @@ -68,7 +68,9 @@ public class MDMAndroidOperationUtil { WebApplication webApplication = new WebApplication(); webApplication.setUrl(application.getLocation()); webApplication.setName(application.getName()); - webApplication.setType(application.getType().toString()); +// webApplication.setType(application.getType().toString()); +// Hard-corded "type" to "webapp". Some agent versions accept only "webapp" as the type. + webApplication.setType("webapp"); webApplication.setProperties(application.getProperties()); operation.setPayLoad(webApplication.toJSON()); break; @@ -111,7 +113,9 @@ public class MDMAndroidOperationUtil { WebApplication webApplication = new WebApplication(); webApplication.setUrl(application.getLocation()); webApplication.setName(application.getName()); - webApplication.setType(application.getType().toString()); +// webApplication.setType(application.getType().toString()); +// Hard-corded "type" to "webapp". Some agent versions accept only "webapp" as the type. + webApplication.setType("webapp"); operation.setPayLoad(webApplication.toJSON()); break; default: