changeset 1b58e7633baf in modules/timesheet:6.2
details: https://hg.tryton.org/modules/timesheet?cmd=changeset&node=1b58e7633baf
description:
        Allow null origin also to GET requests

        The Origin header is also set for GET requests made by JavaScript.

        issue11691
        review417911004
        (grafted from 2466a04c55bb8d913d19485c61d571d46ec04241)
diffstat:

 routes.py |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (27 lines):

diff -r ca41bcd50ab7 -r 1b58e7633baf routes.py
--- a/routes.py Mon Nov 01 17:09:01 2021 +0100
+++ b/routes.py Tue Sep 13 00:20:53 2022 +0200
@@ -14,6 +14,7 @@
 
 
 @app.route('/<database_name>/timesheet/employees', methods=['GET'])
+@allow_null_origin
 @with_pool
 @with_transaction()
 @timesheet_application
@@ -25,6 +26,7 @@
 
 @app.route('/<database_name>/timesheet/employee/<int:employee>/works',
     methods=['GET'])
+@allow_null_origin
 @with_pool
 @with_transaction()
 @timesheet_application
@@ -50,6 +52,7 @@
 
 @app.route('/<database_name>/timesheet/employee/<int:employee>/lines/<date>',
     methods=['GET'])
+@allow_null_origin
 @with_pool
 @with_transaction()
 @timesheet_application

Reply via email to