From f68bfc3768c6a3bb0aa77cf946b7abcdaeb4b2f1 Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Mon, 24 Jun 2024 16:23:00 +0200 Subject: [PATCH] Automatically append a dot if the name ends with the zone name without dot. Fixes #3 --- scripts/knotctl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/knotctl b/scripts/knotctl index 000aaad..8768c51 100755 --- a/scripts/knotctl +++ b/scripts/knotctl @@ -175,6 +175,8 @@ def setup_url( zone += "." url += "/{}".format(zone) if name and zone: + if name.endswith(zone.rstrip(".")): + name += '.' url += "/records/{}".format(name) if zone and name and rtype: url += "/{}".format(rtype)