mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
let multiplayer name be set in browser storage rather than fully anonymous
This commit is contained in:
@@ -42,7 +42,7 @@ module.exports = {
|
||||
let user = opts.user
|
||||
if (!user || user.anonymous) {
|
||||
user = user || { anonymous: true }
|
||||
user.username = `Anon ${Math.floor(Math.random()*100)}`
|
||||
user.username = opts?.data?.name || `Anon ${Math.floor(Math.random()*100)}`
|
||||
}
|
||||
session = {
|
||||
session: opts.data.session,
|
||||
|
Reference in New Issue
Block a user