Add robots.txt

This commit is contained in:
Dylan 2023-08-13 14:25:06 +01:00
parent 0c6e760b72
commit 35a1906d3d

View File

@ -45,6 +45,10 @@ def isValidUserAgent(user_agent):
return True
return False
@app.route('/robots.txt')
def robots():
return "User-agent: *\nDisallow: /"
@app.route('/') # If the useragent is discord, return the embed, if not, redirect to configured repo directly
def default():
user_agent = request.headers.get('user-agent')