Make role name validation case insensitive
Role names are not case sensitive, so need to convert the name to lowercase and make a judgement. Change-Id: I389d264004d7cd3adce1784a3a9fcf89f994fcdf Closes-Bug: #1821679
This commit is contained in:
committed by
Dmitriy Chubinidze
parent
a95d703c98
commit
b2dd0fe5d5
@@ -61,7 +61,7 @@
|
|||||||
},
|
},
|
||||||
$validators: {
|
$validators: {
|
||||||
rolesExists: function (name) {
|
rolesExists: function (name) {
|
||||||
return (roles.indexOf(name) === -1);
|
return (roles.indexOf(name.toLowerCase()) === -1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -118,7 +118,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getName(item) {
|
function getName(item) {
|
||||||
return item.name;
|
return item.name.toLowerCase();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user