Handle chat push notifications and navigate to GlobalChat
This commit is contained in:
3
App.js
3
App.js
@@ -135,6 +135,9 @@ const MainNavigation = ({ route }) => {
|
|||||||
if (data.post_id) {
|
if (data.post_id) {
|
||||||
mainNavigation.navigate("SinglePost", { postid: data.post_id });
|
mainNavigation.navigate("SinglePost", { postid: data.post_id });
|
||||||
}
|
}
|
||||||
|
if (data.type === "chat") {
|
||||||
|
mainNavigation.navigate("GlobalChat");
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
alert("Error: " + error);
|
alert("Error: " + error);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user