aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers
diff options
context:
space:
mode:
Diffstat (limited to 'server/helpers')
-rw-r--r--server/helpers/requests.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/server/helpers/requests.ts b/server/helpers/requests.ts
index 5eb69486d..fd2a56f30 100644
--- a/server/helpers/requests.ts
+++ b/server/helpers/requests.ts
@@ -170,9 +170,11 @@ function buildGotOptions (options: PeerTubeRequestOptions) {
170 170
171 let headers = options.headers || {} 171 let headers = options.headers || {}
172 172
173 headers = { ...headers, date: new Date().toUTCString() } 173 if (!headers.date) {
174 headers = { ...headers, date: new Date().toUTCString() }
175 }
174 176
175 if (activityPub) { 177 if (activityPub && !headers.accept) {
176 headers = { ...headers, accept: ACTIVITY_PUB.ACCEPT_HEADER } 178 headers = { ...headers, accept: ACTIVITY_PUB.ACCEPT_HEADER }
177 } 179 }
178 180