From 869262a8fecf3b069fcd57b9fbe740d6c42c6d03 Mon Sep 17 00:00:00 2001 From: "deepsource-autofix[bot]" <62050782+deepsource-autofix[bot]@users.noreply.github.com> Date: Sun, 25 Jun 2023 19:49:38 +0000 Subject: [PATCH 1/2] style: format code with black Format code with black This commit fixes the style issues introduced in dda7d10 according to the output from Black. Details: https://app.deepsource.com/gh/Fluffy-Bean/GameExpo23/transform/0024b6a1-2a20-4f24-89ec-3c412f85ace7/ --- TFR/server/account.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/TFR/server/account.py b/TFR/server/account.py index af8a117..0bda683 100644 --- a/TFR/server/account.py +++ b/TFR/server/account.py @@ -50,9 +50,9 @@ def post_settings(): twitch = request.form.get("twitch", "").strip() youtube = request.form.get("youtube", "").strip() - twitter_regex = re.compile('^(?!.*\.\.)(?!.*\.$)[\w.]{1,15}$') - twitch_regex = re.compile('^(?=.{4,25}$)(?!_)(?!.*[_.]{2})[a-zA-Z0-9._]+$') - youtube_regex = re.compile('^(?!.*[._]{2})[a-zA-Z0-9._-]{1,50}$') + twitter_regex = re.compile("^(?!.*\.\.)(?!.*\.$)[\w.]{1,15}$") + twitch_regex = re.compile("^(?=.{4,25}$)(?!_)(?!.*[_.]{2})[a-zA-Z0-9._]+$") + youtube_regex = re.compile("^(?!.*[._]{2})[a-zA-Z0-9._-]{1,50}$") error = [] From 8995843f74a5b6da38d2ea81ba2c8bdb9b952a69 Mon Sep 17 00:00:00 2001 From: "deepsource-autofix[bot]" <62050782+deepsource-autofix[bot]@users.noreply.github.com> Date: Sun, 25 Jun 2023 19:51:20 +0000 Subject: [PATCH 2/2] refactor: autofix issues in 1 file Resolved issues in TFR/server/account.py with DeepSource Autofix --- TFR/server/account.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TFR/server/account.py b/TFR/server/account.py index 0bda683..fdd3235 100644 --- a/TFR/server/account.py +++ b/TFR/server/account.py @@ -50,7 +50,7 @@ def post_settings(): twitch = request.form.get("twitch", "").strip() youtube = request.form.get("youtube", "").strip() - twitter_regex = re.compile("^(?!.*\.\.)(?!.*\.$)[\w.]{1,15}$") + twitter_regex = re.compile(r"^(?!.*\.\.)(?!.*\.$)[\w.]{1,15}$") twitch_regex = re.compile("^(?=.{4,25}$)(?!_)(?!.*[_.]{2})[a-zA-Z0-9._]+$") youtube_regex = re.compile("^(?!.*[._]{2})[a-zA-Z0-9._-]{1,50}$")