Direct message rooms are only visible to sender after importing CSV file

Description

Server Setup Information

  • Version of Rocket.Chat Server: 4.1.2
  • Operating System: ubuntu
  • Deployment Method:
  • Number of Running Instances: 1
  • DB Replicaset Oplog:
  • NodeJS Version: 12.22.1
  • MongoDB Version: 4.0.27
  • Proxy:
  • Firewalls involved:

Any additional Information

Hi, I’m using my own chat service for my app, and I have decided to migrate to rocketchat. I exported all users and direct messages to CSV files based on https://docs.rocket.chat/guides/administration/admin-panel/import/csv
and all users and direct messages are imported. But there is a problem I’m facing right now. Direct messages are only visible to users who started the conversation.
For example, user A has sent a message to user B , after importing the data, user A can see chatbox with user B and all the messages are available , but user B can not see the chat box with user A. But if user B searches for user A, clicks on the user to create a direct message with that user, all previous messages will appear for user B.
I was wondering how to fix this issue. any help would be appreciated