mirror of
https://github.com/logos-storage/logos-storage-marketplace-ui.git
synced 2026-01-02 13:33:06 +00:00
Do not block when port forwarding is not enabled
This commit is contained in:
parent
20f5b75a9f
commit
a577db89fa
@ -37,14 +37,10 @@ export function HealthChecks({ online, onStepValid }: Props) {
|
||||
|
||||
useEffect(
|
||||
() => {
|
||||
if (codex.isSuccess) {
|
||||
persistence.refetch();
|
||||
portForwarding.refetch().then(({ data }) => {
|
||||
onStepValid(data?.reachable || false);
|
||||
});
|
||||
} else {
|
||||
onStepValid(false);
|
||||
}
|
||||
persistence.refetch();
|
||||
portForwarding.refetch();
|
||||
|
||||
onStepValid(codex.isSuccess);
|
||||
},
|
||||
// We really do not want to add persistence and portForwarding as
|
||||
// dependencies because it will cause a re-render every time.
|
||||
@ -163,18 +159,6 @@ export function HealthChecks({ online, onStepValid }: Props) {
|
||||
</span>
|
||||
Internet connection
|
||||
</li>
|
||||
<li>
|
||||
<span>
|
||||
{portForwarding.isFetching ? (
|
||||
<Spinner></Spinner>
|
||||
) : portForwarding.enabled ? (
|
||||
<SuccessCircleIcon></SuccessCircleIcon>
|
||||
) : (
|
||||
<ErrorCircleIcon width={16} />
|
||||
)}
|
||||
</span>
|
||||
Port forwarding
|
||||
</li>
|
||||
<li>
|
||||
<span>
|
||||
{codex.isFetching ? (
|
||||
@ -187,6 +171,18 @@ export function HealthChecks({ online, onStepValid }: Props) {
|
||||
</span>
|
||||
Codex connection
|
||||
</li>
|
||||
<li>
|
||||
<span>
|
||||
{portForwarding.isFetching ? (
|
||||
<Spinner></Spinner>
|
||||
) : portForwarding.enabled ? (
|
||||
<SuccessCircleIcon></SuccessCircleIcon>
|
||||
) : (
|
||||
<WarningIcon width={16} />
|
||||
)}
|
||||
</span>
|
||||
Port forwarding
|
||||
</li>
|
||||
<li>
|
||||
<span>
|
||||
{persistence.isFetching ? (
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user