Skip to content

Commit fd01b91

Browse files
authored
Merge branch 'master' into fix/crashes-add-edit-delete-comment-args
2 parents 9cdcfd2 + c045360 commit fd01b91

12 files changed

Lines changed: 1309 additions & 219 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## Version 25.03.xx
2+
Fixes:
3+
- [web] Use Client Hints
4+
15
## Version 25.03.37
26
Fixes:
37
- [core] Update home page download notification text

api/utils/common.js

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1308,9 +1308,13 @@ common.returnRaw = function(params, returnCode, body, heads) {
13081308
}
13091309
return;
13101310
}
1311-
const defaultHeaders = {};
1311+
const defaultHeaders = {
1312+
'Accept-CH': 'Sec-CH-UA, Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version, Sec-CH-UA-Full-Version, Sec-CH-UA-Model',
1313+
'Critical-CH': 'Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version',
1314+
'X-Countly': 'api'
1315+
};
13121316
//set provided in configuration headers
1313-
let headers = {};
1317+
let headers = { ...defaultHeaders };
13141318
if (heads) {
13151319
for (var i in heads) {
13161320
headers[i] = heads[i];
@@ -1356,7 +1360,10 @@ common.returnMessage = function(params, returnCode, message, heads, noResult = f
13561360
}
13571361
//set provided in configuration headers
13581362
const defaultHeaders = {
1359-
'Content-Type': 'application/json; charset=utf-8'
1363+
'Content-Type': 'application/json; charset=utf-8',
1364+
'Accept-CH': 'Sec-CH-UA, Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version, Sec-CH-UA-Full-Version, Sec-CH-UA-Model',
1365+
'Critical-CH': 'Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version',
1366+
'X-Countly': 'api'
13601367
};
13611368
let headers = { ...defaultHeaders };
13621369
var add_headers = (plugins.getConfig("security").api_additional_headers || "").replace(/\r\n|\r|\n/g, "\n").split("\n");
@@ -1431,7 +1438,10 @@ common.returnOutput = function(params, output, noescape, heads) {
14311438
}
14321439
//set provided in configuration headers
14331440
const defaultHeaders = {
1434-
'Content-Type': 'application/json; charset=utf-8'
1441+
'Content-Type': 'application/json; charset=utf-8',
1442+
'Accept-CH': 'Sec-CH-UA, Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version, Sec-CH-UA-Full-Version, Sec-CH-UA-Model',
1443+
'Critical-CH': 'Sec-CH-UA-Mobile, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version',
1444+
'X-Countly': 'api'
14351445
};
14361446
let headers = { ...defaultHeaders };
14371447
var add_headers = (plugins.getConfig("security").api_additional_headers || "").replace(/\r\n|\r|\n/g, "\n").split("\n");

0 commit comments

Comments
 (0)