Fixed redirecting issue