1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-22 06:39:44 +02:00

feat: Store accessToken in cookies instead of localStorage

This commit is contained in:
Maksim Eltyshev 2022-04-26 18:01:55 +05:00
parent 536064fdfe
commit 486e663a3d
27 changed files with 137 additions and 114 deletions

View file

@ -3,20 +3,20 @@ import { transformAction } from './actions';
/* Actions */
const createCommentAction = (cardId, data, headers) =>
socket.post(`/cards/${cardId}/comment-actions`, data, headers).then((body) => ({
const createCommentAction = (cardId, data) =>
socket.post(`/cards/${cardId}/comment-actions`, data).then((body) => ({
...body,
item: transformAction(body.item),
}));
const updateCommentAction = (id, data, headers) =>
socket.patch(`/comment-actions/${id}`, data, headers).then((body) => ({
const updateCommentAction = (id, data) =>
socket.patch(`/comment-actions/${id}`, data).then((body) => ({
...body,
item: transformAction(body.item),
}));
const deleteCommentAction = (id, headers) =>
socket.delete(`/comment-actions/${id}`, undefined, headers).then((body) => ({
const deleteCommentAction = (id) =>
socket.delete(`/comment-actions/${id}`).then((body) => ({
...body,
item: transformAction(body.item),
}));