From 6e09b4245f3a96560ca0eb74d46e8fd40a164f44 Mon Sep 17 00:00:00 2001 From: Brian Kim Date: Wed, 19 May 2021 17:26:40 -0700 Subject: Fix redirect --- src/components/profile/TaggAvatar.tsx | 2 ++ src/components/taggs/TaggDraggable.tsx | 14 +++++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) (limited to 'src/components') diff --git a/src/components/profile/TaggAvatar.tsx b/src/components/profile/TaggAvatar.tsx index 8ccae2ef..8cd52a2f 100644 --- a/src/components/profile/TaggAvatar.tsx +++ b/src/components/profile/TaggAvatar.tsx @@ -23,6 +23,8 @@ const TaggAvatar: React.FC = ({ userXId, editable = false, }) => { + const state = useSelector((state: RootState) => state); + console.log('STATE', state.userX); const {avatar, user} = useSelector((state: RootState) => userXId ? state.userX[screenType][userXId] : state.user, ); diff --git a/src/components/taggs/TaggDraggable.tsx b/src/components/taggs/TaggDraggable.tsx index ac494a6b..06185bd1 100644 --- a/src/components/taggs/TaggDraggable.tsx +++ b/src/components/taggs/TaggDraggable.tsx @@ -79,19 +79,23 @@ const TaggDraggable: React.FC = ( onLayout={(event) => console.log(event.nativeEvent.layout)}> gotoTaggedProfile(taggedUser.userId)} - disabled={false} + disabled={redirect} style={[styles.button]} ref={draggableRef}> @{taggedUser.username} - deleteFromList()}> - - + {redirect && ( + deleteFromList()}> + + + )} -- cgit v1.2.3-70-g09d2