Closed inseokr closed 3 years ago
The group channel is created only after typing another message?
It is added to list_of_group_chats at least.
Client's not sending "new" API for the group channel, but sending update API instead.
pushCurrentChannelToDD will trigger update API.
Let's check where we're generating new API for group channel.
This is happening because loadChattingDatabase is called 2 times.
The following 2 information should be provided.
requestedChannel.channelName, members: requestedChannel.members
Channel couldn't be found (node:19924) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'channel_id' of null at C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\db_utilities\chatting_db\access_chat_db.js:67:74 at new Promise ()
at Object.addChannelToSingleUser (C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\db_utilities\chatting_db\access_chat_db.js:62:10)
at C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\routes\chatting\index.js:62:18
at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:19924) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag )
at Object.addChannelToSingleUser (C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\db_utilities\chatting_db\access_chat_db.js:62:10)
at C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\routes\chatting\index.js:62:18
at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:19924) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag
--unhandled-rejections=strict
(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2) (node:19924) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. removeSocket: userName = inseo SOCKET IS BEING DISCONNECTED!!!!!!!!!!!!!!!!!!!! (node:19924) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'channel_id' of null at C:\Users\inseo\linkedspaces\master\MERN_linkedspace\src\server\db_utilities\chatting_db\access_chat_db.js:67:74 at new Promise (--unhandled-rejections=strict
(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 4)