Skip to content

Commit 29ac682

Browse files
authored
fix: add missing clearSession native options (#1289)
1 parent 967dfa5 commit 29ac682

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

src/hooks/Auth0Context.ts

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ import type {
2020
ResetPasswordParameters,
2121
MfaChallengeResponse,
2222
} from '../types';
23-
import type { NativeAuthorizeOptions } from '../types/platform-specific';
23+
import type {
24+
NativeAuthorizeOptions,
25+
NativeClearSessionOptions,
26+
} from '../types/platform-specific';
2427
import type { AuthState } from './reducer';
2528

2629
/**
@@ -43,10 +46,14 @@ export interface Auth0ContextInterface extends AuthState {
4346
/**
4447
* Clears the user's session and logs them out.
4548
* @param parameters The parameters to send to the `/v2/logout` endpoint.
49+
* @param options Platform-specific options to customize the logout experience.
4650
* @returns A promise that resolves when the session has been cleared.
4751
* @throws {AuthError} If the logout fails.
4852
*/
49-
clearSession(parameters?: ClearSessionParameters): Promise<void>;
53+
clearSession(
54+
parameters?: ClearSessionParameters,
55+
options?: NativeClearSessionOptions
56+
): Promise<void>;
5057

5158
/**
5259
* Saves the user's credentials.

0 commit comments

Comments
 (0)