Skip to content
Snippets Groups Projects
Commit f31028aa authored by Jan Hartig's avatar Jan Hartig
Browse files

Dev

parent 8d552602
No related branches found
No related tags found
1 merge request!26Dev
......@@ -47,7 +47,7 @@ async def unlock_room(request: Request):
if room.lower() == entry["room"].lower():
return json_response({"error": "Raum nicht freischaltbar."})
except KeyError:
except (KeyError, TypeError):
room = get_random_room()
# Make room name url-safe
......@@ -110,7 +110,7 @@ def check_auth(request: Request) -> dict:
def get_random_room() -> str:
return f"{r.word(include_parts_of_speech=['adjectives'])}{r.word(include_parts_of_speech=['nouns'])}"
return f"{r.word(include_parts_of_speech=['adjectives']).capitalize()}{r.word(include_parts_of_speech=['nouns']).capitalize()}"
async def get_serial2room():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment