tajnymag / tinder-deblur

Simple script using the official Tinder API to get clean photos of the users who liked you
MIT License
293 stars 29 forks source link

Fix deblurring when photos are at images-ssl.gotinder.com #12

Closed aamezua closed 1 year ago

aamezua commented 1 year ago

Solve deblurring when photos are in images-ssl.gotinder.com

tajnymag commented 1 year ago

Could you, please, try this version? https://gist.github.com/tajnymag/ba18f441ce28b543a31b379f61ebbe38/raw/3058a5847596c4b1429e6ef1ece5c122a8a303ad/tinder.user.js

I've applied a few brush strokes to your script to make it a bit more readable and concise. I'm not really sure about the logic which handles urls that already contain "preview". It feels wrong to leave them unmodified.

aamezua commented 1 year ago

It did not work for urls with "preview" because the if clause was causing the code skipping the cases. I fixed it modifying the if clause. Try it in https://github.com/aamezua/tinder-deblur/blob/images-ssl/tinder.user.js

tajnymag commented 1 year ago

I know, I know, I'm being late. I just had a VERY busy week. And with Christmas on horizon (almost literally) I'll get to it the earliest on Sunday or Monday.

aamezua commented 1 year ago

Oh!! Excuse me. I did not want to be pushy. I am not very familiar with the process (I am sure you noticed) and I was not sure the changes were properly committed.

tajnymag commented 1 year ago

You were right, I did skip the cases with preview in the image url. So far, there's only two cases that can happen, either the image includes preview or images-ssl. I refactored the if-else logic into a single if check. I take preview as default and reassign it when the case does not suit.

Do I understand it right?

Newly updated version: https://gist.github.com/tajnymag/ba18f441ce28b543a31b379f61ebbe38

aamezua commented 1 year ago

Yes. I tried and works great! I believe we can close the issue #12

tajnymag commented 1 year ago

Awesome. I'll close it after I push my changes and merge your PR

tajnymag commented 1 year ago

Thank you once again. Once the service refreshes its cache, you should be listed as our new contributor at the bottom of the README :)