Skip to content

Commit

Permalink
Fix settings
Browse files Browse the repository at this point in the history
  • Loading branch information
Janaka-Steph committed Nov 9, 2023
1 parent 8a7cd33 commit 526d8c4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/controller/dockerController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,8 @@ class DockerController extends AbstractServiceController {
}

async fetchRegistries(): Promise<Registry[]> {
return await api().get(`v1/registries/`);
const response = await api().get(`v1/registries/`);
return response.data;
}

async resetDefaultRegistry(): Promise<void> {
Expand Down
4 changes: 2 additions & 2 deletions src/modules/settings/components/domain/Domains.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ const Domains = () => {

useEffect(() => {
(async () => {
const dnsInfo = await apiDnsd().get("dns/existing");
setDomains(dnsInfo.data.map((dnsInfo: { domain: any }) => dnsInfo.domain));
const { data } = await apiDnsd().get("dns/existing");
setDomains(data?.map((dnsInfo: { domain: any }) => dnsInfo.domain) ?? []);
})();
}, []);

Expand Down

0 comments on commit 526d8c4

Please sign in to comment.