diff options
author | Paul Frazee <pfrazee@gmail.com> | 2024-09-12 11:09:58 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-12 11:09:58 -0700 |
commit | 47bea320619b5854a56029c04ea001b9bbb19ccd (patch) | |
tree | 1968da7f9bc9c4d6b9a6aec64cf0fdd2c6909e50 | |
parent | 897d8ba744c576ee954dfc79ec4deac176b47a6a (diff) | |
download | voidsky-47bea320619b5854a56029c04ea001b9bbb19ccd.tar.zst |
Add a hard-coded redirect for lulaoficial.bsky.social (#5303)
-rw-r--r-- | src/view/screens/Profile.tsx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/view/screens/Profile.tsx b/src/view/screens/Profile.tsx index 37111c02e..5ef645981 100644 --- a/src/view/screens/Profile.tsx +++ b/src/view/screens/Profile.tsx @@ -41,6 +41,7 @@ import {ProfileFeedSection} from '#/screens/Profile/Sections/Feed' import {ProfileLabelsSection} from '#/screens/Profile/Sections/Labels' import {ScreenHider} from '#/components/moderation/ScreenHider' import {ProfileStarterPacks} from '#/components/StarterPack/ProfileStarterPacks' +import {navigate} from '#/Navigation' import {ExpoScrollForwarderView} from '../../../modules/expo-scroll-forwarder' import {ProfileFeedgens} from '../com/feeds/ProfileFeedgens' import {ProfileLists} from '../com/lists/ProfileLists' @@ -86,6 +87,16 @@ export function ProfileScreen({route}: Props) { } }, [resolveError, refetchDid, refetchProfile]) + // Apply hard-coded redirects as need + React.useEffect(() => { + if (resolveError) { + if (name === 'lulaoficial.bsky.social') { + console.log('Applying redirect to lula.com.br') + navigate('Profile', {name: 'lula.com.br'}) + } + } + }, [name, resolveError]) + // When we open the profile, we want to reset the posts query if we are blocked. React.useEffect(() => { if (resolvedDid && profile?.viewer?.blockedBy) { |