diff --git a/frontend/lib/api/user.ts b/frontend/lib/api/user.ts index e55bab9..7a6b122 100644 --- a/frontend/lib/api/user.ts +++ b/frontend/lib/api/user.ts @@ -2,19 +2,13 @@ import { BaseAPI, route } from "./base"; import { ItemsApi } from "./classes/items"; import { LabelsApi } from "./classes/labels"; import { LocationsApi } from "./classes/locations"; +import { UserOut } from "./types/data-contracts"; import { Requests } from "~~/lib/requests"; export type Result = { item: T; }; -export type User = { - name: string; - email: string; - isSuperuser: boolean; - id: number; -}; - export class UserApi extends BaseAPI { locations: LocationsApi; labels: LabelsApi; @@ -30,7 +24,7 @@ export class UserApi extends BaseAPI { } public self() { - return this.http.get>({ url: route("/users/self") }); + return this.http.get>({ url: route("/users/self") }); } public logout() {