Skip to content
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

feat: delete function with count and start id params #137

Closed

Conversation

thiagocavalcanti
Copy link
Contributor

This function allows to delete messages, with a count parameter (which counts from the last message to the very first one) and an id parameter in which we can use to start the count from a specific message

ex:
deleteMessages(1) will delete the last message

deleteMessages(2,'2123-12313-123') will delete the message with id '2123-12313-123' and the message before that

Copy link
Contributor

@mcallegari10 mcallegari10 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome functionality, I will try to add it in the next version! Tank you very much and sorry for the delay :)

@thiagocavalcanti
Copy link
Contributor Author

Hey @mcallegari10, I think we can close this, right? Also, i saw the implementation in v3.0, but it's a little bit different. It seems to me that if you provide (2, "AN_ID"), it'll only remove the message with the id and not the message before it.

@thiagocavalcanti
Copy link
Contributor Author

thiagocavalcanti commented May 10, 2021

@mcallegari10, If it makes sense, I opened this PR containing the fix: #254

@mcallegari10
Copy link
Contributor

Yeah, it makes sense, the feature was kinda incomplete. @thiagocavalcanti, thanks! I'll review it 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants