auto redirect to client