diff --git a/index.js b/index.js index 03c000d..1400df1 100644 --- a/index.js +++ b/index.js @@ -14,4 +14,13 @@ module.exports = Franz => class MicrosoftTeams extends Franz { 'skypeforbusiness.com', ]; } + + // we need to allow all cookies for ms teams + onHeadersReceived(details, callback) { + if (details.responseHeaders && details.responseHeaders['Set-Cookie'] && details.responseHeaders['Set-Cookie'].length && !details.responseHeaders['Set-Cookie'][0].includes('SameSite=none')) { + // eslint-disable-next-line no-param-reassign + details.responseHeaders['Set-Cookie'][0] = `${details.responseHeaders['Set-Cookie'][0]}; SameSite=none`; + } + callback({ cancel: false, responseHeaders: details.responseHeaders }); + } }; diff --git a/package.json b/package.json index 28cb41b..240d059 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "id": "msteams", "name": "Microsoft Teams", - "version": "1.2.1", + "version": "1.3.0", "description": "Microsoft Teams", "main": "index.js", "author": "Stefan Malzner ",