mirror of
https://github.com/outline/outline.git
synced 2026-06-13 03:14:59 +03:00
bf45e97641
* Update types * fix circular dep * type imports * lint type imports and --fix
19 lines
476 B
TypeScript
19 lines
476 B
TypeScript
import type ApiKey from "@server/models/ApiKey";
|
|
import presentUser from "./user";
|
|
|
|
export default function presentApiKey(apiKey: ApiKey) {
|
|
return {
|
|
id: apiKey.id,
|
|
user: presentUser(apiKey.user),
|
|
userId: apiKey.userId,
|
|
name: apiKey.name,
|
|
scope: apiKey.scope,
|
|
value: apiKey.value,
|
|
last4: apiKey.last4,
|
|
createdAt: apiKey.createdAt,
|
|
updatedAt: apiKey.updatedAt,
|
|
expiresAt: apiKey.expiresAt,
|
|
lastActiveAt: apiKey.lastActiveAt,
|
|
};
|
|
}
|