[fix] depreciation warning about unicode

Co-authored-by: Alexandre Aubin <alex.aubin@mailoo.org>
This commit is contained in:
ljf (zamentur) 2022-05-06 15:36:28 +02:00 committed by GitHub
parent 76661a3e6c
commit 6f5bb03b2d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -500,7 +500,7 @@ def _get_relative_name_for_dns_zone(domain, base_dns_zone):
# foo.example.tld -> foo
# .foo.example.tld -> foo
# bar.foo.example.tld -> bar.foo
return re.sub("\.?" + base_dns_zone.replace(".", "\.") + "$", "", domain.strip(".")) or "@"
return re.sub(r"\.?" + base_dns_zone.replace(".", r"\.") + "$", "", domain.strip(".")) or "@"
def _get_registrar_config_section(domain):