-
Notifications
You must be signed in to change notification settings - Fork 136
feat: add filter query for link_preview_options #783
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
Conversation
i am not sure if this is as easy as this..
|
Nice, did you test this locally? Does it work as expected? |
|
steps i did to test locally: I was not able to test the but by testing below code, I found one const privateComposer = composer.chatType("private");
privateComposer.on("::url", async ctx => {
console.log(ctx.update);
const urls = ctx.entities(["url"]);
console.log(urls); //
});by testing with the below message. The Can you let me know what are the expectations? |
|
The filter query |
KnorpelSenf
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
What needs to be done to move this out of draft state and get this ready to be merged?
Ok, What about the |
|
That's a great catch. I think it makes no sense to filter for bot.on("::url").drop(Context.has.filterQuery(":link_preview_options"))which effectively only gives you messages URL entities but without link preview. |
Co-authored-by: KnorpelSenf <[email protected]>
|
@all-contributors add @SpEcHiDe for idea and code and test |
|
I've put up a pull request to add @SpEcHiDe! 🎉 |


Based on the message_thread
Please let me know if this is expected approach.