Skip to content

Commit

Permalink
use changes from develop
Browse files Browse the repository at this point in the history
  • Loading branch information
alecananian committed Mar 13, 2024
1 parent af85437 commit d83e55d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 42 deletions.
15 changes: 0 additions & 15 deletions apps/tlon-mobile/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ import {
} from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
import { TamaguiProvider } from '@tloncorp/ui';
import type { Subscription } from 'expo-notifications';
import { addNotificationResponseReceivedListener } from 'expo-notifications';
import { PostHogProvider } from 'posthog-react-native';
import { useEffect, useState } from 'react';
import { StatusBar, Text, View } from 'react-native';
Expand Down Expand Up @@ -58,22 +56,9 @@ const App = ({ wer }: Props) => {
const screenOptions = useScreenOptions();

useEffect(() => {
let notificationTapListener: Subscription | undefined;
if (isAuthenticated) {
// Start notification tap listener
// This only seems to get triggered on iOS. Android handles the tap and other intents in native code.
notificationTapListener = addNotificationResponseReceivedListener(
handleNotificationResponse
);

connectNotifications();
syncContacts();
}

return () => {
// Clean up listeners
notificationTapListener?.remove();
};
}, [isAuthenticated]);

useEffect(() => {
Expand Down
27 changes: 0 additions & 27 deletions apps/tlon-mobile/src/utils/notifications.ts

This file was deleted.

0 comments on commit d83e55d

Please sign in to comment.