Skip to content
Snippets Groups Projects
Commit 955efba2 authored by BiggestGuz's avatar BiggestGuz
Browse files

Frontend http requests are now put where they need to be

parent f2dacffc
No related branches found
No related tags found
1 merge request!41Resolve "Update frontend post to puts where applicable"
......@@ -162,7 +162,7 @@ export const updateUserInfo = async (
'email': email,
'profilePictureBase64': profilePictureBase64
};
return await axios.post('http://localhost:8080/users/update',data,config);
return await axios.put('http://localhost:8080/users/update',data,config);
} catch (error){
console.error(error)
throw error;
......@@ -184,7 +184,7 @@ export const updatePasswordInfo = async (
'password': currentPassword,
'newPassword': newPassword
};
return await axios.post('http://localhost:8080/userCredentials/updatePassword',data,config);
return await axios.put('http://localhost:8080/userCredentials/updatePassword',data,config);
} catch (error){
console.error(error)
throw error;
......@@ -205,7 +205,7 @@ export const updateBankAccountInfo = async (
'currentAccount': checkingAccount,
'savingAccount': savingAccount
};
return await axios.post('http://localhost:8080/users/update',data,config);
return await axios.put('http://localhost:8080/users/update',data,config);
} catch (error){
console.error(error)
throw error;
......@@ -229,7 +229,7 @@ export const updateIncomeInfo = async (
'monthlyFixedExpenses': monthlyFixedExpenses,
'monthlySavings': monthlySavings
};
return await axios.post('http://localhost:8080/users/update',data,config);
return await axios.put('http://localhost:8080/users/update',data,config);
} catch (error){
console.error(error)
throw error;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment