diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.view/view.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.view/view.js
index 997711701c..f16ea8db7c 100644
--- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.view/view.js
+++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.view/view.js
@@ -18,8 +18,6 @@
function onRequest(context) {
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
- var username = request.getParameter("username");
- var user = userModule.getUser(username)["content"];
var deviceMgtProps = require("/app/modules/conf-reader/main.js")["conf"];
var isExsistingUser = false;
var userName = request.getParameter("username");
@@ -49,7 +47,8 @@ function onRequest(context) {
}
var canEdit = false;
- if (userModule.isAuthorized("/permission/admin/device-mgt/users/edit")) {
+ if (userModule.isAuthorized("/permission/admin/device-mgt/users/edit") &&
+ userName !== deviceMgtProps['adminUser'].split("@")[0]) {
canEdit = true;
}
diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.geo-dashboard/public/assets/html_templates/modal/speed_alert.html b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.geo-dashboard/public/assets/html_templates/modal/speed_alert.html
index c8145f5f53..308f036c9a 100644
--- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.geo-dashboard/public/assets/html_templates/modal/speed_alert.html
+++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.geo-dashboard/public/assets/html_templates/modal/speed_alert.html
@@ -34,7 +34,7 @@