From fcff1f085422ae6761d7d74c799500d6c1fd6102 Mon Sep 17 00:00:00 2001 From: dilanua Date: Fri, 12 Aug 2016 20:00:46 +0530 Subject: [PATCH] Fixing user menu reg exp issue --- .../units/cdmf.unit.ui.header.user-menu/public/js/user-menu.js | 1 + 1 file changed, 1 insertion(+) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.ui.header.user-menu/public/js/user-menu.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.ui.header.user-menu/public/js/user-menu.js index fe168cc0e0..9547a1e50d 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.ui.header.user-menu/public/js/user-menu.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.ui.header.user-menu/public/js/user-menu.js @@ -6,6 +6,7 @@ * @returns {boolean} Returns true if input matches RegEx */ function inputIsValid(regExp, inputString) { + regExp = new RegExp(regExp); return regExp.test(inputString); }