Hey guys i didnt have this problem when I was building the app locally but as soon as i uploaded I have this problem I think Im not setting the url correctly for the post request, I say this cuz i get 200 for the request itself but its not sending the info I want its sending some bs from my index.html
Code:
const onSave= (price,time,carrierName)=>{
if(isAuthenticated=== true){
axios.post(`https://fathomless-ravine-04271.herokuapp.com/savedInfo/save`,{departureName,
price,destinationName,userId,carrierName,time,departureDate,userName})
.then(res => console.log(res.data))
}else{
return(
<p>Needs Login</p>
)
}
}
pic: