mirror of
https://github.com/woodchen-ink/nezha-dash-v1.git
synced 2025-07-18 09:31:55 +08:00
fix: safely check nezhaWsData.servers before rendering
This commit is contained in:
parent
d302df895a
commit
964e53e33b
@ -71,7 +71,7 @@ export function DashCommand() {
|
||||
<CommandInput placeholder={t("TypeCommand")} value={search} onValueChange={setSearch} />
|
||||
<CommandList>
|
||||
<CommandEmpty>{t("NoResults")}</CommandEmpty>
|
||||
{nezhaWsData.servers.length > 0 && (
|
||||
{nezhaWsData.servers && nezhaWsData.servers.length > 0 && (
|
||||
<>
|
||||
<CommandGroup heading={t("Servers")}>
|
||||
{nezhaWsData.servers.map((server) => (
|
||||
|
Loading…
x
Reference in New Issue
Block a user