clean up wants flow and http usage

This commit is contained in:
ntr committed 2022-11-28 10:31:37 +11:00
1 parent e74ab36313
commit 631942bb41
8 files changed
+30 -34

No files matched your search

+4 -15
View File
@@ -32,21 +32,7 @@ function onError(error) {
api.interceptors.response.use(onSuccess, onError);
const actions = {
getBundles: async function getBundles() {
return api.get('/acp/bundles');
},
getOffers: async function getOffers() {
return api.get('/user/offers');
},
getOffersAcp: async function getOffersAcp() {
return api.get('/acp/offers');
},
getWants: async function getWants() {
return api.get('/want/all');
},
// TODO move to rpc
postWantSearch: async function postWantSearch(query) {
return api.post('/want/search', { query });
@@ -60,6 +46,9 @@ const actions = {
return api.post('/want/discogs', { username });
},
// --------------------------------
// require as http to set cookies
getLogin: async function getLogin() {
return api.get('/auth/login')
},