mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-06 22:20:55 +03:00
added hmac auth to report route
Co-authored-by: timvisee <tim@visee.me>
This commit is contained in:
@@ -61,7 +61,10 @@ async function fetchWithAuth(url, params, keychain) {
|
||||
const result = {};
|
||||
params = params || {};
|
||||
const h = await keychain.authHeader();
|
||||
params.headers = new Headers({ Authorization: h });
|
||||
params.headers = new Headers({
|
||||
Authorization: h,
|
||||
'Content-Type': 'application/json'
|
||||
});
|
||||
const response = await fetch(url, params);
|
||||
result.response = response;
|
||||
result.ok = response.ok;
|
||||
|
||||
Reference in New Issue
Block a user