fixed redirect issue