Nachname hinzugefügt

This commit is contained in:
hubobel 2026-02-14 18:36:49 +01:00
parent 2520b1bba5
commit c5f08470a4

View file

@ -463,10 +463,12 @@ def zufName(geschlecht):
with resource_path("namen.json").open(encoding="utf-8") as f: with resource_path("namen.json").open(encoding="utf-8") as f:
data = json.load(f) data = json.load(f)
if geschlecht == "P": # Frau if geschlecht == "P": # Frau
return random.choice(data["Frau"]) name = random.choice(data["Frau"]) + " " +random.choice(data["Nachnamen"])
return name
# Default: Mann # Default: Mann
return random.choice(data["Mann"]) name = random.choice(data["Mann"]) + " " + random.choice(data["Nachnamen"])
return name
def delete(pfad_ogg): def delete(pfad_ogg):
if pfad_ogg.exists(): if pfad_ogg.exists():
try: try: