Skip to content

Commit

Permalink
Add SDK token for PayPal domain
Browse files Browse the repository at this point in the history
  • Loading branch information
elizabethmv committed Dec 4, 2023
1 parent 71b5b83 commit 83593d9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import {
import { getPath, getDefaultNamespace, getSDKHost } from "./global";
import { CLIENT_ID_ALIAS } from "./config";
import { getComputedLocales } from "./utils";
import { isPayPalDomain } from "./domains";

type GetSDKScript = () => HTMLScriptElement;

Expand Down Expand Up @@ -338,6 +339,10 @@ export function getUserExperienceFlow(): ?string {
return getSDKAttribute(SDK_SETTINGS.USER_EXPERIENCE_FLOW);
}

export function getSDKToken(): ?string {
isPayPalDomain() ? getSDKAttribute(SDK_SETTINGS.SDK_TOKEN) : "";
}

// whether in zoid window
export function isChildWindow(): boolean {
return Boolean(window.xprops);
Expand Down

0 comments on commit 83593d9

Please sign in to comment.