File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
examples/SampleApp/src/components Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -64,7 +64,13 @@ export const BackButton: React.FC<{
6464 return (
6565 < TouchableOpacity
6666 onPress = { ( ) => {
67- navigation . goBack ( ) ;
67+ if ( ! navigation . canGoBack ( ) ) {
68+ // if no previous screen was present in history, go to the list screen
69+ // this can happen when opened through push notification
70+ navigation . reset ( { index : 0 , routes : [ { name : 'HomeScreen' } ] } ) ;
71+ } else {
72+ navigation . goBack ( ) ;
73+ }
6874 if ( onBack ) {
6975 onBack ( ) ;
7076 }
Original file line number Diff line number Diff line change @@ -302,7 +302,6 @@ export const UserInfoOverlay = (props: UserInfoOverlayProps) => {
302302 members,
303303 } ) ;
304304
305- console . log ( 'channels' , channels . length ) ;
306305 let newChannel ;
307306 if ( channels . length === 1 ) {
308307 newChannel = channels [ 0 ] ;
You can’t perform that action at this time.
0 commit comments