Remove redirect and handle in nginx instead