refactor: add user info to authData

This commit is contained in:
Tristan Yang
2022-06-29 10:56:50 +08:00
parent c5694a07b0
commit aff66ad5c8
37 changed files with 94 additions and 104 deletions
+2 -11
View File
@@ -29,21 +29,12 @@ const NavItem = ({ id, setFiles, toggleRemoveConfirm }) => {
handleContextMenuEvent,
hideContextMenu
} = useContextMenu();
const {
channel,
mids,
messageData,
readIndex,
muted,
loginUid
// loginUser,
} = useSelector((store) => {
const { channel, mids, messageData, readIndex, muted, loginUid } = useSelector((store) => {
return {
// loginUser: store.contacts.byId[store.authData.uid],
channel: store.channels.byId[id],
mids: store.channelMessage[id],
messageData: store.message,
loginUid: store.authData.uid,
loginUid: store.authData.user?.uid,
readIndex: store.footprint.readChannels[id],
muted: store.footprint.muteChannels[id]
};