mirror of
https://github.com/pretix/pretix.git
synced 2026-11-08 01:06:40 +00:00
Fix TypeError if task.request.headers is None (#6367)
This commit is contained in:
1 parent
430c6dd269
commit
7f847c3dd2
1 file changed
+1
-1
@@ -59,7 +59,7 @@ def on_task_prerun(sender, task_id, task, **kwargs):
|
||||
from pretix.helpers.logs import local
|
||||
|
||||
local.request_id = task_id
|
||||
if "X-Pretix-Trace" in task.request.headers:
|
||||
if task.request.headers and "X-Pretix-Trace" in task.request.headers:
|
||||
local.trace = task.request.headers["X-Pretix-Trace"].split(" ")
|
||||
else:
|
||||
local.trace = []
|
||||
|
||||
Reference in new issue
Block a user