mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-20 22:00:43 +08:00
Query all local repos by getting the local repo count
Instead of falling back to the default of 10 repos, set by radicle-httpd. We query the local httpd instance for the amount of repos hosted.
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import type { ProjectListQuery } from "@httpd-client";
|
||||
|
||||
import { loadProjectActivity, type WeeklyActivity } from "@app/lib/commit";
|
||||
import {
|
||||
HttpdClient,
|
||||
@@ -15,10 +17,10 @@ export interface ProjectInfo {
|
||||
|
||||
export async function fetchProjectInfos(
|
||||
baseUrl: BaseUrl,
|
||||
show: "all" | "pinned",
|
||||
query?: ProjectListQuery,
|
||||
): Promise<ProjectInfo[]> {
|
||||
const api = new HttpdClient(baseUrl);
|
||||
const projects = await api.project.getAll({ show });
|
||||
const projects = await api.project.getAll(query);
|
||||
const info = await Promise.all(
|
||||
projects.map(async project => {
|
||||
const [activity, lastCommit] = await Promise.all([
|
||||
|
||||
Reference in New Issue
Block a user