diff --git a/ui/src/app/components/errors/Errors.js b/ui/src/app/components/errors/Errors.js index c2c1f76..2ce8bcd 100644 --- a/ui/src/app/components/errors/Errors.js +++ b/ui/src/app/components/errors/Errors.js @@ -73,7 +73,7 @@ const Error = ({error, onDismiss}) => { {rs && of {rs.name}} {errorStatus}.

-

If this problem persist, we suggest you +

If this problem persists, we suggest you try again later.

); diff --git a/ui/src/app/components/navigation/RouteServers.js b/ui/src/app/components/navigation/RouteServers.js index dafab95..8e86ff6 100644 --- a/ui/src/app/components/navigation/RouteServers.js +++ b/ui/src/app/components/navigation/RouteServers.js @@ -33,15 +33,17 @@ const Status = ({routeServerId}) => { }); }, [routeServerId, handleError]); - if (error && error.code >= 100 && error.code < 200) { + const errorInfo = error?.response?.data; + + if (errorInfo && errorInfo.tag === "CONNECTION_REFUSED") { return (
- unreachable + route server unreachable
); - } else if (error?.response?.data?.tag === "GENERIC_ERROR") { + } else if (errorInfo && errorInfo.tag === "GENERIC_ERROR") { return (
@@ -49,11 +51,11 @@ const Status = ({routeServerId}) => {
); - } else if (error) { + } else if (errorInfo) { return (
- {error.response?.data?.tag} + {errorInfo.tag}
);