made it so that config rules load in alphabetical order

This commit is contained in:
maskedmonkyman 2022-03-22 13:11:37 -07:00
parent b1c80d1266
commit 1349f62893

View File

@ -332,9 +332,13 @@
modes_list.innerHTML = "";
reader.addEventListener("load", (event) => {
let vote_rules = JSON.parse(event.target.result);
for (let mode of vote_rules.modes)
add_mode(mode);
for (let rule in vote_rules.rules)
let rules = Object.keys(vote_rules.rules).sort()
for (let rule of rules)
{
let rule_element = build_rule_element();
rule_element.rule_string_input.value = rule;