Use a predetermined default password length field

This commit is contained in:
2023-04-16 20:41:33 +02:00
parent 605f345dc0
commit 0987b4c280
3 changed files with 14 additions and 6 deletions

View File

@@ -4,7 +4,8 @@ namespace Common;
public static class PasswordGenerator
{
public static Error? ExceptionOccured;
private static string RandomStr(int length, bool no_symbols = false)
public static int DEFAULT_LENGTH = 16;
private static string RandomStr(int length = 16, bool no_symbols = false)
{
StringBuilder builder = new StringBuilder();
Random rnd = new Random();