mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-13 06:34:39 -04:00
15 lines
445 B
TypeScript
15 lines
445 B
TypeScript
/*
|
|
* SPDX-FileCopyrightText: 2022 The HedgeDoc developers (see AUTHORS file)
|
|
*
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
*/
|
|
import { DeleteApiRequestBuilder } from '../common/api-request-builder/delete-api-request-builder'
|
|
|
|
/**
|
|
* Requests to log out the current user.
|
|
*
|
|
* @throws {Error} if logout is not possible.
|
|
*/
|
|
export const doLogout = async (): Promise<void> => {
|
|
await new DeleteApiRequestBuilder('auth/logout').sendRequest()
|
|
}
|