Add referer check to redirect