setting up redirect function from other plugin