fixed http redirect problem