Fixing redirect.js