9639bd1757
Move utils used by /server/tools/* & /server/tests/**/* into /shared folder. Issue: #1336
17 lines
429 B
TypeScript
17 lines
429 B
TypeScript
import { makePutBodyRequest } from '../requests/requests'
|
|
|
|
async function updateRedundancy (url: string, accessToken: string, host: string, redundancyAllowed: boolean, expectedStatus = 204) {
|
|
const path = '/api/v1/server/redundancy/' + host
|
|
|
|
return makePutBodyRequest({
|
|
url,
|
|
path,
|
|
token: accessToken,
|
|
fields: { redundancyAllowed },
|
|
statusCodeExpected: expectedStatus
|
|
})
|
|
}
|
|
|
|
export {
|
|
updateRedundancy
|
|
}
|