Every now and then, I’ll come across the perfect piece of code that makes everything right.  More often than not, the next time I need it, I can’t remember where I found it or even where I put it.

This is my attempt at fixing that.