7514066fc3
* move settings * remove meteor cache files
14 lines
430 B
TypeScript
14 lines
430 B
TypeScript
const setCookie = (sessions: Array<string>) => {
|
|
const COOKIE_CONFIG = window.meetingClientSettings.public.pads.cookie;
|
|
const PATH = COOKIE_CONFIG.path;
|
|
const SAME_SITE = COOKIE_CONFIG.sameSite;
|
|
const SECURE = COOKIE_CONFIG.secure;
|
|
|
|
const sessionIds = sessions.join(',');
|
|
document.cookie = `sessionID=${sessionIds}; path=${PATH}; SameSite=${SAME_SITE}; ${SECURE ? 'Secure' : ''}`;
|
|
};
|
|
|
|
export default {
|
|
setCookie,
|
|
};
|