Skip to content

Commit

Permalink
Refactor membership test
Browse files Browse the repository at this point in the history
  • Loading branch information
kjd committed Sep 14, 2024
1 parent 762216b commit 4ed183d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion idna/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ def uts46_remap(domain: str, std3_rules: bool = True, transitional: bool = False
status = uts46row[1]
replacement: Optional[str] = None
if std3_rules and code_point <= 0x7F:
if not code_point in _ldh:
if code_point not in _ldh:
raise InvalidCodepoint(
"Codepoint {} at position {} does not follow STD3 rules".format(_unot(code_point), pos + 1)
)
Expand Down

0 comments on commit 4ed183d

Please sign in to comment.