mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-19 02:51:14 +00:00
refactor(editor): Stricter linting for promises and async functions (no-changelog) (#4642)
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
import type { IRestApiContext } from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
|
||||
export function getApiKey(context: IRestApiContext): Promise<{ apiKey: string | null }> {
|
||||
export async function getApiKey(context: IRestApiContext): Promise<{ apiKey: string | null }> {
|
||||
return makeRestApiRequest(context, 'GET', '/me/api-key');
|
||||
}
|
||||
|
||||
export function createApiKey(context: IRestApiContext): Promise<{ apiKey: string | null }> {
|
||||
export async function createApiKey(context: IRestApiContext): Promise<{ apiKey: string | null }> {
|
||||
return makeRestApiRequest(context, 'POST', '/me/api-key');
|
||||
}
|
||||
|
||||
export function deleteApiKey(context: IRestApiContext): Promise<{ success: boolean }> {
|
||||
export async function deleteApiKey(context: IRestApiContext): Promise<{ success: boolean }> {
|
||||
return makeRestApiRequest(context, 'DELETE', '/me/api-key');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user