Important fix: Not allow create char if limit is exceeded (by @anyeor )

Could have been used to spam database, now it doesn't ignore deleted characters

He is not my brother :P Just same last name
This commit is contained in:
slawkens
2023-06-27 15:02:28 +02:00
parent a810890614
commit aab62fb724
2 changed files with 2 additions and 2 deletions

View File

@@ -138,7 +138,7 @@ class CreateCharacter
if(empty($errors))
{
$number_of_players_on_account = $account->getPlayersList(false)->count();
$number_of_players_on_account = $account->getPlayersList(true)->count();
if($number_of_players_on_account >= config('characters_per_account'))
$errors[] = 'You have too many characters on your account <b>('.$number_of_players_on_account.'/'.config('characters_per_account').')</b>!';
}