-
Notifications
You must be signed in to change notification settings - Fork 17
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
[AmazonProduct] Shorten links even more #168
Comments
This will be available in the next release 😃 |
Nice! |
Duplicates #160, but I'm glad it's fixed from here. |
This trick works also with amazon.it |
It frankly likely works across all of Amazon.[TLD]. @svenjacobs Is there a method setup for that sort of thing in Léon? |
Yes, the underlying regex is designed so that it works with all Amazon domains. @TPS What should the method set up? |
I meant something that could work across many TLDs, but the same owner & pattern (like Amazon's above or Google's). |
@TPS I still don't understand, sorry 😉 When we write a sanitizer for a domain that is known to have multiple TLDs, we generally design the regex as such. I don't know if it makes sense to have an option that makes any TLDs available for all existing sanitizers? |
This is what I was verifying, & whether that was done for, e.g., Amazon.[TLD], Google.[TLD], &c
No, certainly not generally, but, if turns out that existing/requested sanitizer needed to be written wide enough for |
Hey there! I love your work, really appreciate it =)
I found something for the amazon product link shortener:
https://www.amazon.de/Xiaomi-Aktivit%C3%A4tstracker-Trainings-Puls%C3%BCberwachung-Akkulaufzeit/dp/B091G3FLL7/?_encoding=UTF8&pd_rd_w=xDcJP&pf_rd_p=bf172aca-3277-41f6-babb-6ce7fc34cf7f&pf_rd_r=ZC6FZ5G6W9K8DEZTPBYW&pd_rd_r=11b3ec4e-047c-4f37-8302-62dedb8f502b&pd_rd_wg=Ozi90&ref_=pd_gw_ci_mcx_mr_hp_atf_m
https://www.amazon.de/Xiaomi-Aktivit%C3%A4tstracker-Trainings-Puls%C3%BCberwachung-Akkulaufzeit/dp/B091G3FLL7/
(which is good...)https://www.amazon.de/dp/B091G3FLL7/
. Only the/dp/
followed by the product id is a valid amazon link as well and in some cases (where the product title is long) can be much shorterSo this should be
result shouldBe "https://www.amazon.de/dp/B091G3FLL7/"
Furthermore I think there might be a test missing for links from other countries like
.co.uk
(multiple dots)The text was updated successfully, but these errors were encountered: