Skip to content

Commit

Permalink
PR changes
Browse files Browse the repository at this point in the history
  • Loading branch information
anku255 committed Jan 16, 2024
1 parent dce825c commit dfefab3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion bundle/website.js

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions test/with-typescript/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,8 @@ import { BooleanClaim, PrimitiveClaim, SessionClaimValidator } from "../../recip
import { PermissionClaim, UserRoleClaim } from "../../recipe/userroles";
import { CookieHandlerReference } from "../../utils/cookieHandler";
import { WindowHandlerReference } from "../../utils/windowHandler";
import { DateProviderReference } from "../../utils/dateProvider";
import { DateProviderInput, DateProviderInterface } from "../../utils/dateProvider/types";

// Email verification init
function getEmailVerificationFunctions(original: EmailVerificationRecipeInterface): EmailVerificationRecipeInterface {
Expand Down Expand Up @@ -1068,11 +1070,20 @@ const cookieHandlerInput: CookieHandlerInput = (original: CookieHandlerInterface
};
};

const dateProviderImplementation: DateProviderInterface = {
getClientClockSkewInMillis: () => 0,
setClientClockSkewInMillis: () => {},
now: () => Date.now(),
};

const dateProviderInput: DateProviderInput = () => dateProviderImplementation;

SuperTokens.init({
appInfo,
recipeList,
windowHandler: windowHandlerInput,
cookieHandler: cookieHandlerInput,
dateProvider: dateProviderInput,
});

SuperTokens.init({
Expand Down Expand Up @@ -2010,4 +2021,5 @@ Session.addAxiosInterceptors({});
function reexportedHandlers() {
CookieHandlerReference.getReferenceOrThrow();
WindowHandlerReference.getReferenceOrThrow();
DateProviderReference.getReferenceOrThrow();
}

0 comments on commit dfefab3

Please sign in to comment.