change redirect to js