Yet another attempt to handle redirection.