From 9f0906373496c5b9818e2a73694cdfd8b058d303 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Tue, 8 Aug 2023 09:57:40 +1000 Subject: [PATCH] bot: Updated regex for handshake domains to allow SLDs --- bot.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/bot.py b/bot.py index 46b75b6..e26bf47 100644 --- a/bot.py +++ b/bot.py @@ -13,7 +13,7 @@ client = discord.Client(intents=intents) tree = app_commands.CommandTree(client) icann_regex = r'^https://[a-z0-9]+(\.[a-z0-9]+)+(/[a-zA-Z0-9-.]*)*$' -handshake_regex = r'^[a-z0-9]+$' +handshake_regex = r'^[a-z0-9]+(\.[a-z0-9]+)*$' @tree.command(name = "mirror", description = "Create a mirror of an ICANN site on a Handshake domain") async def mirror(interaction, handshakedomain: str, icannurl: str): @@ -158,11 +158,6 @@ async def gitpull(interaction, handshakedomain: str): await user.send("Changes pulled for " + handshakedomain + "!") - - - - - def get_tlsa(input_string): lines = input_string.split("\n") for line in lines: