@intra-mart/smartlime 2.0.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -57,6 +57,7 @@ const useRequest = (setter, getter) => {
|
|
|
57
57
|
const currentCookies = getter()?.cookies;
|
|
58
58
|
const params = makeEncodeParams(clientTypeId);
|
|
59
59
|
const response = await imFetch(`api/bearer/smacolow/session?${params}`, {
|
|
60
|
+
credentials: 'include',
|
|
60
61
|
headers: {
|
|
61
62
|
Accept: 'application/json',
|
|
62
63
|
'X-Intramart-Session': 'keep', // https://document.intra-mart.jp/library/iap/public/im_web_api_maker/im_web_api_maker_programming_guide/texts/how_to_use_api/index.html#session-management
|
|
@@ -114,8 +115,10 @@ const useGetSessionAsync = (request, destroy, getter) => {
|
|
|
114
115
|
const { cookies } = getter();
|
|
115
116
|
if (cookies) {
|
|
116
117
|
const response = await imFetch('api/smacolow/session', {
|
|
118
|
+
credentials: 'include',
|
|
117
119
|
headers: {
|
|
118
120
|
Cookie: makeCookie(cookies),
|
|
121
|
+
'X-Intramart-Session': 'keep', // https://document.intra-mart.jp/library/iap/public/im_web_api_maker/im_web_api_maker_programming_guide/texts/how_to_use_api/index.html#session-management
|
|
119
122
|
},
|
|
120
123
|
method: 'GET',
|
|
121
124
|
});
|
package/package.json
CHANGED