mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
[ticket/15766] Use proper variable name for permission set
PHPBB3-15766
This commit is contained in:
parent
11cf09b41a
commit
18e75202d7
1 changed files with 4 additions and 4 deletions
|
@ -322,21 +322,21 @@ function match_role_settings(id)
|
||||||
{
|
{
|
||||||
var fs = document.getElementById(id),
|
var fs = document.getElementById(id),
|
||||||
cbs = fs.getElementsByTagName('input'),
|
cbs = fs.getElementsByTagName('input'),
|
||||||
xyz = {};
|
set = {};
|
||||||
|
|
||||||
for (var i = 0; i < cbs.length; i++) {
|
for (var i = 0; i < cbs.length; i++) {
|
||||||
var matches = cbs[i].id.match(/setting\[\d+]\[\d+]\[([a-z_]+)]/);
|
var matches = cbs[i].id.match(/setting\[\d+]\[\d+]\[([a-z_]+)]/);
|
||||||
|
|
||||||
if (matches !== null && cbs[i].checked && cbs[i].value !== '-1') {
|
if (matches !== null && cbs[i].checked && cbs[i].value !== '-1') {
|
||||||
xyz[matches[1]] = parseInt(cbs[i].value);
|
set[matches[1]] = parseInt(cbs[i].value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
xyz = sort_and_stringify(xyz);
|
set = sort_and_stringify(set);
|
||||||
|
|
||||||
for (var r in role_options)
|
for (var r in role_options)
|
||||||
{
|
{
|
||||||
if (sort_and_stringify(role_options[r]) === xyz) {
|
if (sort_and_stringify(role_options[r]) === set) {
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue