the request getting to the server without the headers:
const res = await axios.post(`/api/follow/${props.match.url}`, { headers: { Authorization: `Bearer ${token}`, userId: userId, }, });
anyone knows why?
should just put null in the body place, and it works
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.