()
| 30 | } |
| 31 | |
| 32 | export function readPendingOAuthCredentialDraft(): PendingOAuthCredentialDraft | null { |
| 33 | if (typeof window === 'undefined') return null |
| 34 | return parseJson<PendingOAuthCredentialDraft>( |
| 35 | window.sessionStorage.getItem(PENDING_OAUTH_CREDENTIAL_DRAFT_KEY) |
| 36 | ) |
| 37 | } |
| 38 | |
| 39 | export function writePendingOAuthCredentialDraft(payload: PendingOAuthCredentialDraft) { |
| 40 | if (typeof window === 'undefined') return |