swaps logout to POST instead of GET

This commit is contained in:
James
2020-08-11 16:00:55 -04:00
parent fe2c1e69e5
commit 258d4cd62e
2 changed files with 2 additions and 2 deletions

View File

@@ -65,7 +65,7 @@ const UserProvider = ({ children }) => {
const logOut = () => {
setUser(null);
setTokenInMemory(null);
requests.get(`${serverURL}${api}/${userSlug}/logout`);
requests.post(`${serverURL}${api}/${userSlug}/logout`);
};
// On mount, get user and set

View File

@@ -74,7 +74,7 @@ function registerCollections() {
router
.route(`/${slug}/logout`)
.get(logout);
.post(logout);
router
.route(`/${slug}/refresh-token`)