ubershmekel/redditp — pull request #14 by vosechu (2013-06-28 04:43:35+00:00)
Title: Add GIF toggle

Sometimes I like to auto-play r/funny but I don't want to see gifs. I know I'm pretty much alone in this but if you're willing this would make my life better. :)

Changes:

This adds the checkbox, adds a cookie, and on reload it removes the gifs. Preview: http://d.pr/i/RPyi
Checkbox is checked by default so nobody should see any impact unless they untoggle.

Questions:

I wasn't sure whether to force a reload when you click the gif checkbox. The setting doesn't take effect until after that reload. For now I have it reloading. Thoughts?
Line 492 is confusing for me. If the image is a gif from imgur, it adds .jpg onto the back which makes it a valid gif again. This change I did seems to make it work but I don't understand why.

Apologies:

Sorry for the white-space removal. My editor does that by default.

Thanks:

Thank you for building this project. It's super helpful and the best I've found.