fixed bug on redirect of page