Remove the user fetch endpoint

This commit is contained in:
2026-07-19 23:52:18 +03:00
Unverified
parent 4703fe6dec
commit a152a52b03
5 changed files with 6 additions and 26 deletions
-10
View File
@@ -2,16 +2,6 @@ import { API_BASE_URL } from "@/core/config";
import { getAuthHeaders } from "./auth";
import type { User } from "@/core/types";
/**
* Fetches a list of all users (excluding current user)
*/
export async function fetchUsers(token: string): Promise<User[]> {
const res = await fetch(`${API_BASE_URL}/users`, { headers: getAuthHeaders(token, true) });
if (!res.ok) return [];
const data = await res.json();
return data.users || [];
}
/**
* Searches for users by username query
*/