mirror of https://github.com/jumpserver/jumpserver
Merge pull request #10722 from jumpserver/pr@dev@perf_json_filter_m2m
perf: 优化 json m2m filterpull/10723/head
commit
aad804f1af
|
@ -502,7 +502,7 @@ class JSONManyToManyDescriptor:
|
||||||
value = [value.id]
|
value = [value.id]
|
||||||
value = set(map(str, value))
|
value = set(map(str, value))
|
||||||
rule_value = set(map(str, rule_value))
|
rule_value = set(map(str, rule_value))
|
||||||
res &= rule_value.issubset(value)
|
res &= value.issubset(rule_value)
|
||||||
else:
|
else:
|
||||||
logging.error("unknown match: {}".format(rule['match']))
|
logging.error("unknown match: {}".format(rule['match']))
|
||||||
res &= False
|
res &= False
|
||||||
|
|
Loading…
Reference in New Issue