diff --git a/webui/src/lib/api/index.js b/webui/src/lib/api/index.js index cb4f3dccce5..7604baf7a88 100644 --- a/webui/src/lib/api/index.js +++ b/webui/src/lib/api/index.js @@ -61,8 +61,8 @@ export const parseRawHeaders = (rawHeaders) => { const headerLines = cleanedHeadersString.split('\n'); const parsedHeaders = headerLines.reduce((acc, line) => { let [key, ...value] = line.split(':'); // split into key and the rest of the value - key = key.trim(); - value = value.join(':').trim(); + key = key.trim(); + value = value.join(':').trim(); if (key && value) { acc[key.toLowerCase()] = value; } @@ -458,8 +458,9 @@ class Repositories { return response.json(); } - async list(prefix = "", after = "", amount = DEFAULT_LISTING_AMOUNT) { - const query = qs({prefix, after, amount}); + async list(search = "", after = "", amount = DEFAULT_LISTING_AMOUNT) { + console.log("list search ", search) + const query = qs({search, after, amount}); const response = await apiRequest(`/repositories?${query}`); if (response.status !== 200) { throw new Error(`could not list repositories: ${await extractError(response)}`);