diff --git a/docs/changelogs/unreleased.rst b/docs/changelogs/unreleased.rst
index b49a0a26..a9ca46a3 100644
--- a/docs/changelogs/unreleased.rst
+++ b/docs/changelogs/unreleased.rst
@@ -2,6 +2,11 @@ Unreleased
==========
Added
-:::::::
+:::::
* Proxy: it is now possible to add not exposed endpoints in the proxy configuration.
+
+Fixed
+:::::
+
+* UI: Fixed the topology UI where changing the state of a remote would cause the page to crash (#578, @ArthurD1).
diff --git a/harp_apps/dashboard/frontend/src/Pages/System/Topology/RemoteEndpointStatusDropDown.tsx b/harp_apps/dashboard/frontend/src/Pages/System/Topology/RemoteEndpointStatusDropDown.tsx
index bc46390b..0f035aa3 100644
--- a/harp_apps/dashboard/frontend/src/Pages/System/Topology/RemoteEndpointStatusDropDown.tsx
+++ b/harp_apps/dashboard/frontend/src/Pages/System/Topology/RemoteEndpointStatusDropDown.tsx
@@ -1,5 +1,6 @@
import { Menu, MenuButton, MenuItem, MenuItems } from "@headlessui/react"
import { ChevronDownIcon } from "@heroicons/react/20/solid"
+import { useCallback, useMemo } from "react"
import tw, { styled } from "twin.macro"
import { useSystemProxyMutation } from "Domain/System/useSystemProxyQuery.ts"
@@ -26,8 +27,13 @@ export default function RemoteEndpointStatusDropDown({
}) {
const mutation = useSystemProxyMutation()
const status = remoteEndpoint.status ?? 0
- const humanStatus = getHumanStatus(status)
-
+ const humanStatus = useMemo(() => getHumanStatus(status), [status])
+ const handleMutation = useCallback(
+ (status: string) => {
+ mutation.mutate({ endpoint: endpointName, url: remoteEndpoint.settings.url, action: status })
+ },
+ [mutation, endpointName, remoteEndpoint.settings.url],
+ )
return (