Revert "Remove force_url_to_non_ssl function."

This reverts commit 0678457004cf20113a1f385cd8d840d5545e9011.