mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
pass clusterId query as param
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com>
This commit is contained in:
1 parent
536e9bbd31
commit
f49d3aeb6d
1 file changed
+1
-2
@@ -166,8 +166,7 @@ export async function removePortForward(portForward: ForwardedPort) {
|
||||
|
||||
export async function getPortForwards(clusterId?: string): Promise<ForwardedPort[]> {
|
||||
try {
|
||||
const query = clusterId ? `?clusterId=${clusterId}` : "";
|
||||
const response = await apiBase.get<PortForwardsResult>(`/pods/port-forwards${query}`);
|
||||
const response = await apiBase.get<PortForwardsResult>("/pods/port-forwards", { query: { clusterId }});
|
||||
|
||||
return response.portForwards;
|
||||
} catch (error) {
|
||||
|
||||
Reference in new issue
Block a user