Added href check to services page since href is now optional
This commit is contained in:
parent
691a0ed881
commit
f6258df5a2
1 changed files with 6 additions and 6 deletions
|
@ -4,7 +4,7 @@ import { ReactElement } from 'react'
|
|||
import useSWR from 'swr';
|
||||
import ServiceList from '../public/data/pages.json';
|
||||
import { DockerInfo } from '../interfaces/DockerStatus';
|
||||
import { CardContentService, PageContentBox, PageDescription, PageTitle } from '../components/styles/content';
|
||||
import { PageContentBox, PageDescription, PageTitle } from '../components/styles/content';
|
||||
import useWindowSize from '../components/windowsize';
|
||||
import { ServiceCardMobile } from '../components/styles/cards/mobile';
|
||||
import { ServiceCardDesktop } from '../components/styles/cards/desktop';
|
||||
|
@ -85,7 +85,7 @@ async function getStatus(entry: Service, containers: DockerInfo[]) {
|
|||
// Others to follow but low prio as this is currently the only location used
|
||||
|
||||
// Type APP
|
||||
if (entry.type === ServiceType.app) {
|
||||
if (entry.type === ServiceType.app && entry.href) {
|
||||
await fetch(entry.href)
|
||||
.then((response) => {
|
||||
if (response.ok) {
|
||||
|
|
Loading…
Reference in a new issue