Skip to content

Commit

Permalink
Merge branch 'profile-followers' of github.com:GenerateNU/Algo into p…
Browse files Browse the repository at this point in the history
…rofile-followers
  • Loading branch information
capture120 committed Apr 17, 2024
2 parents fe1a1a6 + 98fc114 commit e6a30e3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion frontend/pages/Profile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ const Profile = () => {
const [pageNumber, setPageNumber] = useState<number>(0);
const [portfolio, setPortfolio] = useState<UserPortfolio>()
const route = useRoute()
const isFollowerProfile = (route.params as ProfileRouteParams)?.user !== undefined;
const user = (route.params as ProfileRouteParams)?.user || session!.user!;

const OnActivitySelected = () => {
Expand Down Expand Up @@ -69,7 +70,9 @@ const Profile = () => {

<View className='flex flex-row'>
<SubTabButton title='Portfolio' selected={pageNumber == 0} onPress={OnPortfolioSelected} />
<SubTabButton title='Activity' selected={pageNumber == 1} onPress={OnActivitySelected} />
{!isFollowerProfile && (
<SubTabButton title='Activity' selected={pageNumber == 1} onPress={OnActivitySelected} />
)}
</View>

<ScrollView
Expand Down

0 comments on commit e6a30e3

Please sign in to comment.