mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2025-12-18 12:07:12 +00:00
refactoring cookie age as a function not a constant
This commit is contained in:
@@ -12,7 +12,7 @@ from troggle.core.models.caves import GetCaveLookup
|
||||
from troggle.core.models.survex import DrawingFile
|
||||
from troggle.core.models.troggle import DataIssue, Expedition, PersonExpedition
|
||||
from troggle.core.utils import (
|
||||
COOKIE_MAX_AGE,
|
||||
get_cookie_max_age,
|
||||
alphabet_suffix,
|
||||
current_expo,
|
||||
get_editor,
|
||||
@@ -755,5 +755,5 @@ def dwgupload(request, folder=None, gitdisable="no"):
|
||||
"who_are_you": editor,
|
||||
},
|
||||
)
|
||||
response.set_cookie('editor_id', editor, max_age=COOKIE_MAX_AGE) # cookie expires after COOKIE_MAX_AGE seconds
|
||||
response.set_cookie('editor_id', editor, max_age=get_cookie_max_age()) # cookie expires after get_cookie_max_age() seconds
|
||||
return response
|
||||
|
||||
Reference in New Issue
Block a user