aboutsummaryrefslogtreecommitdiff
path: root/internal/game/exit_migrate.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/game/exit_migrate.go')
-rw-r--r--internal/game/exit_migrate.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/internal/game/exit_migrate.go b/internal/game/exit_migrate.go
index 1fceca9..2c56d27 100644
--- a/internal/game/exit_migrate.go
+++ b/internal/game/exit_migrate.go
@@ -130,7 +130,10 @@ func (g *Game) RewriteRoomIDs(idMap map[int]int) {
if rewritePlayerRoomIDs(sess.Player, idMap) {
g.saveCharacter(sess.Player)
}
- online[sess.Player.Name] = true
+ // Key case-insensitively: a character file stem can differ in case
+ // from the loaded Player.Name, and a case-sensitive set would miss it
+ // and remap that online character a second time on disk.
+ online[strings.ToLower(sess.Player.Name)] = true
}
}
names, err := g.AccountStore.ListCharacterNames()
@@ -138,7 +141,7 @@ func (g *Game) RewriteRoomIDs(idMap map[int]int) {
return
}
for _, name := range names {
- if online[name] {
+ if online[strings.ToLower(name)] {
continue
}
p, err := g.AccountStore.LoadCharacter(name)