mirror of
https://github.com/MetaCubeX/subconverter.git
synced 2025-09-26 23:09:20 +08:00
Fix Clash classical rule provider not renaming properly
This commit is contained in:
parent
b39de30db9
commit
92f66bf5b5
@ -357,10 +357,10 @@ int renderClashScript(YAML::Node &base_rule, std::vector<RulesetContent> &rulese
|
||||
if(x.rule_type == RULESET_CLASH_IPCIDR || x.rule_type == RULESET_CLASH_DOMAIN || x.rule_type == RULESET_CLASH_CLASSICAL)
|
||||
{
|
||||
//rule_name = std::to_string(hash_(rule_group + rule_path));
|
||||
rule_name = old_rule_name = findFileName(rule_path);
|
||||
rule_name = old_rule_name = urlDecode(findFileName(rule_path));
|
||||
int idx = 2;
|
||||
while(std::find(groups.begin(), groups.end(), rule_name) != groups.end())
|
||||
rule_name = old_rule_name + "_" + std::to_string(idx++);
|
||||
rule_name = old_rule_name + " " + std::to_string(idx++);
|
||||
names[rule_name] = rule_group;
|
||||
urls[rule_name] = "*" + rule_path;
|
||||
rule_type[rule_name] = x.rule_type;
|
||||
|
Loading…
Reference in New Issue
Block a user