Skip to content

Commit

Permalink
change endpoint from admin/namespaces to chooser/namespaces (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiovincenzi authored Mar 28, 2024
1 parent a1f4c21 commit dbbfd3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/src/components/SideBar/SideBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,13 @@ function SideBar(): React.FunctionComponentElement<React.ReactNode> {
}, []);

useEffect(() => {
fetch(`${getBaseHost()}/admin/namespaces/list`)
fetch(`${getBaseHost()}/chooser/namespaces`)
.then((response) => response.json())
.then((data) =>
setNamespaces(data.map((item: { code: any }) => item.code)),
);

fetch(`${getBaseHost()}${getPrefix()}admin/namespaces/current`)
fetch(`${getBaseHost()}${getPrefix()}chooser/namespaces/current`)
.then((response) => response.json())
.then((data) => {
const selected = data.code;
Expand Down

0 comments on commit dbbfd3b

Please sign in to comment.