diff --git a/packages/web_ui/src/components/InstanceViewPage.jsx b/packages/web_ui/src/components/InstanceViewPage.jsx index 58384ab4..4559839c 100644 --- a/packages/web_ui/src/components/InstanceViewPage.jsx +++ b/packages/web_ui/src/components/InstanceViewPage.jsx @@ -1,6 +1,6 @@ import React, { useContext, useState } from "react"; import { useHistory, useParams } from "react-router-dom"; -import { Button, Descriptions, Popconfirm, Space, Spin, Typography } from "antd"; +import { Alert, Button, Descriptions, Popconfirm, Space, Spin, Typography } from "antd"; import DeleteOutlined from "@ant-design/icons/DeleteOutlined"; import { libLink } from "@clusterio/lib"; @@ -41,10 +41,22 @@ export default function InstanceViewPage(props) { return ; } - if (instance.missing) { + if (instance.missing || instance["status"] === "deleted") { return - Instance not found - Instance with id {instanceId} was not found on the master server. + Instance with id {instanceId} was not found on the master server.>} + type="warning" + action={ + { history.push("/instances"); }} + > + Go back to instances list + + } + /> ; }
Instance with id {instanceId} was not found on the master server.