Auth/Fixup

* provide empty values for non-default db fields when initializing external accounts
 * removed browser check for username maxlength as it depends on auth method
This commit is contained in:
Sarjuuk
2025-02-23 01:22:46 +01:00
parent cd4c023c61
commit 83b99c47d2
2 changed files with 2 additions and 2 deletions

View File

@@ -324,7 +324,7 @@ class User
return $_;
}
$newId = DB::Aowow()->query('INSERT IGNORE INTO ?_account (`extId`, `user`, `displayName`, `joinDate`, `prevIP`, `prevLogin`, `locale`, `status`, `userGroups`) VALUES (?d, ?, ?, UNIX_TIMESTAMP(), ?, UNIX_TIMESTAMP(), ?d, ?d, ?d)',
$newId = DB::Aowow()->query('INSERT IGNORE INTO ?_account (`extId`, `user`, `passHash`, `displayName`, `email`, `joinDate`, `allowExpire`, `prevIP`, `prevLogin`, `locale`, `status`, `userGroups`) VALUES (?d, ?, "", ?, "", UNIX_TIMESTAMP(), 0, ?, UNIX_TIMESTAMP(), ?d, ?d, ?d)',
$extId,
$name,
Util::ucFirst($name),

View File

@@ -38,7 +38,7 @@
<table align="center">
<tr>
<td align="right"><?=Lang::account('user').Lang::main('colon'); ?></td>
<td><input type="text" name="username" value="<?=$this->user; ?>" maxlength="16" id="username-generic" style="width: 10em" /></td>
<td><input type="text" name="username" value="<?=$this->user; ?>" id="username-generic" style="width: 10em" /></td>
</tr>
<tr>
<td align="right"><?=Lang::account('pass').Lang::main('colon'); ?></td>