-
Notifications
You must be signed in to change notification settings - Fork 326
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug with Talk::getMessagesByUserId() #123
Comments
Do you want to get All messages from all users? |
I have a problem like yours, i've to do this Talk::getConversationsByUserId($userId, 0, 1000000); to get all the message between the user logged and $userId, i think because the $limit = 20 is taking all the messages in database |
same here, have to do Talk::getConversationsById($conversationId, 0, 100000000); to get the conversation otherwise query limit will prevent retrieval |
Hi there. Perhaps You've got a relatd problem. Also I filtered the deleted_from_sender inside of the retriever function "messages" of the Conversation class. Let me know if that is of use or problematic. Good luck! INFO: Laravel 5.7, nahid/talk v2.2.2 from composer |
I found the same issue, If we use getMessages the $limit=20 seems to have a bug in MySQL for Linux somehow it limits the query take to only 5 items. It doesn't happen in Windows running WAMP though. The safest workaround would be to put "999999999" value on the last parameter. I hope @nahid can check this. Thanks. |
nahid/talk v2.2.1 - Laravel 5.3
Hi, I'm having a bug with Talk :: getMessagesByUserId (). I have more than 3000 records in my database and I have configured Talk :: getMessagesByUserId ($ id, 0, 2000) which is supposed to retrieve 2000 messages from a user. I have 3000 messages in total in the messages table (from different users), the use of Talk :: getMessagesByUserId as I configured it prevents to retrieve the messages and blocks the distribution of the messages of ALL the users. I have to set Talk :: getMessagesByUserId with a max value of 1000000 to take the lead. I think this is a bug because Talk :: getMessagesByUserId is supposed to limit the number of messages to a single user and not to all.
Example of use now to avoid problems :
Maybe I'm wrong in the code too. An idea ?
The text was updated successfully, but these errors were encountered: