mirror of
https://github.com/balzack/databag.git
synced 2025-02-15 21:19:16 +00:00
8 lines
338 B
JavaScript
8 lines
338 B
JavaScript
|
import { checkResponse, fetchWithTimeout } from './fetchUtil';
|
||
|
|
||
|
export async function setChannelNotifications(server, token, channelId, flag) {
|
||
|
const notify = await fetchWithTimeout(`https://${server}/content/channels/${channelId}/notification?agent=${token}`, { method: 'PUT', body: JSON.stringify(flag) });
|
||
|
checkResponse(notify)
|
||
|
}
|
||
|
|