From d6dffc046491feaa5b146fd43f1ec1eee63a2320 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Fri, 25 Aug 2023 14:20:58 +1000 Subject: [PATCH] main: Small fixed for licences --- discord-bot/bot.py | 5 +++++ master/main.py | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/discord-bot/bot.py b/discord-bot/bot.py index 978545f..54a4af5 100644 --- a/discord-bot/bot.py +++ b/discord-bot/bot.py @@ -16,6 +16,11 @@ if Master_Port == None: FREE_LICENCE = os.getenv('FREE_LICENCE') if FREE_LICENCE == None: FREE_LICENCE = False +else: + if FREE_LICENCE.lower() == "true": + FREE_LICENCE = True + else: + FREE_LICENCE = False intents = discord.Intents.default() client = discord.Client(intents=intents) diff --git a/master/main.py b/master/main.py index a4adb5e..45ffc35 100644 --- a/master/main.py +++ b/master/main.py @@ -37,7 +37,7 @@ def new_site(): # Verify both API key and domain exist if api_key == None: - return jsonify({'error': 'Missing API key', 'success': 'false'}) + return jsonify({'error': 'No licence provided', 'success': 'false'}) if domain == None: return jsonify({'error': 'Missing domain', 'success': 'false'})