Skip to content

Commit fc6843e

Browse files
author
Jicheng Lu
committed
minor change
1 parent 67c16aa commit fc6843e

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/lib/services/agent-service.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,11 +115,14 @@ export async function getAgentRuleOptions() {
115115

116116
/**
117117
* Get agent labels
118+
* @param {number?} [size]
118119
* @returns {Promise<string[]>}
119120
*/
120-
export async function getAgentLabels() {
121+
export async function getAgentLabels(size = null) {
121122
const url = endpoints.agentLabelsUrl;
122-
const response = await axios.get(url);
123+
const response = await axios.get(url, {
124+
params: { size: size }
125+
});
123126
return response.data;
124127
}
125128

src/routes/page/agent/+page.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@
123123
}
124124
125125
function getAgentLabelOptions() {
126-
return getAgentLabels().then(res => {
126+
return getAgentLabels(3000).then(res => {
127127
agentLabelOptions = res?.map(x => ({ label: x, value: x })) || [];
128128
}).catch(() => {
129129
agentLabelOptions = [];

0 commit comments

Comments
 (0)