@@ -2,11 +2,11 @@ import '../App.css';
22import showPasswordPrompt from '../components/prompt.js' ;
33
44const LeaderView = ( { TEAM_DATA , UpdateTeamName, newTeamName,
5- SetNewTeamName, BackendHost , SetTeamUpdateMsg } ) => {
5+ SetNewTeamName, SetTeamUpdateMsg } ) => {
66
77 const RemoveMember = async ( member_name ) => {
88 try {
9- const response = await fetch ( `http:// ${ BackendHost } /team/remove-member` , {
9+ const response = await fetch ( `/api /team/remove-member` , {
1010 method : "POST" ,
1111 headers : {
1212 "Content-Type" : "application/json"
@@ -34,7 +34,7 @@ const LeaderView = ({ TEAM_DATA, UpdateTeamName, newTeamName,
3434 } ;
3535 const AddMember = async ( req_id , checksum ) => {
3636 try {
37- const response = await fetch ( `http:// ${ BackendHost } /team/add-member` , {
37+ const response = await fetch ( `/api /team/add-member` , {
3838 method : "POST" ,
3939 headers : {
4040 "Content-Type" : "application/json"
@@ -65,7 +65,7 @@ const LeaderView = ({ TEAM_DATA, UpdateTeamName, newTeamName,
6565
6666 const LeaderLeaving = async ( passwd ) => {
6767 try {
68- const response = await fetch ( `http:// ${ BackendHost } /team/replace-leader` , {
68+ const response = await fetch ( `/api /team/replace-leader` , {
6969 method : "POST" ,
7070 headers : {
7171 "Content-Type" : "application/json"
0 commit comments