This commit is contained in:
j3d1 2026-08-27 03:14:01 +02:00
parent 9685b4020e
commit 22931452e3
7 changed files with 28 additions and 21 deletions

View file

@ -370,11 +370,11 @@ export default createStore({
servers.add(home)
for (const friend of friends) {
try {
const s = await dispatch('lookupServer', {username: friend.username})
const s = await dispatch('lookupServer', {username: friend.handle})
servers.add(new ServerSet(s, state.unreachable_neighbors))
} catch (e) {
// Skip an unresolvable/unreachable friend rather than aborting the whole lookup.
console.error('could not resolve server for friend', friend.username, e)
console.error('could not resolve server for friend', friend.handle, e)
}
}
return servers
@ -893,13 +893,13 @@ export default createStore({
groupInventoryItems: (state) => (groupHandle) => state.item_map['/' + groupHandle] || [],
groupStorageLocations: (state) => (groupHandle) => state.location_map['/' + groupHandle] || [],
identityIdByHandle(state) {
return Object.fromEntries(state.idmap.identities.map(i => [i.username, i.id]))
return Object.fromEntries(state.idmap.identities.map(i => [i.handle, i.id]))
},
groupIdByHandle(state) {
return Object.fromEntries(state.idmap.groups.map(g => [g.handle, g.id]))
},
identityHandleById(state) {
return Object.fromEntries(state.idmap.identities.map(i => [i.id, i.username]))
return Object.fromEntries(state.idmap.identities.map(i => [i.id, i.handle]))
},
groupHandleById(state) {
return Object.fromEntries(state.idmap.groups.map(g => [g.id, g.handle]))