Skip to content

Commit

Permalink
Merge branch 'main' into feat/MSSDK-2126-create-primer-component-with…
Browse files Browse the repository at this point in the history
  • Loading branch information
m4tewoosh committed Feb 12, 2025
2 parents e7a370e + e1910fa commit 268da01
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
"dev-vite": "vite dev",
"preview": "vite preview",
"lint-fix": "pnpm lint --fix",
"dev": "pnpm --prefix ../mediastore-sdk-demo-2024 dev & onchange './src/**' -e './src/**/*.(spec|test|type|types).[jt]s?(x)' -- pnpm publish-dev",
"dev": "pnpm --prefix ../mediastore-sdk-demo-2024 dev & onchange --kill './src/**' -e './src/**/*.(spec|test|type|types).[jt]s?(x)' -- pnpm publish-dev",
"dev-windows": "start /B cmd /c pnpm --prefix ..\\mediastore-sdk-demo-2024 dev & onchange \"./src/**\" -e \"./src/**/*.(spec|test|type|types).[jt]s?(x)\" -- pnpm publish-dev"
},
"browserslist": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { getData } from 'util/appConfigHelper';
import { fetchWithHeaders } from 'util/fetchHelper';
import fetchWithJWT from 'util/fetchHelper';
import getApiURL from 'util/environmentHelper';
import getCustomer from './getCustomer';

const getOfferDetails = async (offerId) => {
const getOfferDetails = async (offerId: string) => {
const API_URL = getApiURL();
let customerEmail = getData('CLEENG_CUSTOMER_EMAIL') || null;

Expand All @@ -15,7 +15,9 @@ const getOfferDetails = async (offerId) => {
}
const url = `${API_URL}/offers/${offerId}/customers/${customerEmail}`;

return fetchWithHeaders(url, {})
return fetchWithJWT(url, {
method: 'GET'
})
.then(async (res) => {
const { responseData, errors } = await res.json();
if (!res.ok) {
Expand Down

0 comments on commit 268da01

Please sign in to comment.