fix http vs. https problem