fixes for alias display + check aliases on initial uid generation
This commit is contained in:
@@ -113,7 +113,7 @@ namespace MareSynchronosServer.Hubs
|
||||
userToOther.UserUID == userid
|
||||
select new
|
||||
{
|
||||
otherEntry.OtherUser.Alias,
|
||||
userToOther.OtherUser.Alias,
|
||||
userToOther.IsPaused,
|
||||
OtherIsPaused = otherEntry != null && otherEntry.IsPaused,
|
||||
userToOther.OtherUserUID,
|
||||
|
||||
@@ -166,7 +166,7 @@ public class DiscordBot : IHostedService
|
||||
while (!hasValidUid)
|
||||
{
|
||||
var uid = GenerateRandomString(10);
|
||||
if (db.Users.Any(u => u.UID == uid)) continue;
|
||||
if (db.Users.Any(u => u.UID == uid || u.Alias == uid)) continue;
|
||||
user.UID = uid;
|
||||
hasValidUid = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user