forked from orbit-oss/flask
support timedelta for SEND_FILE_MAX_AGE_DEFAULT config variable
This commit is contained in:
parent
1ac4156016
commit
d526932a09
5 changed files with 36 additions and 7 deletions
|
|
@ -17,14 +17,11 @@ from werkzeug.http import http_date, parse_date
|
|||
from werkzeug.datastructures import CallbackDict
|
||||
from . import Markup, json
|
||||
from ._compat import iteritems, text_type
|
||||
from .helpers import total_seconds
|
||||
|
||||
from itsdangerous import URLSafeTimedSerializer, BadSignature
|
||||
|
||||
|
||||
def total_seconds(td):
|
||||
return td.days * 60 * 60 * 24 + td.seconds
|
||||
|
||||
|
||||
class SessionMixin(object):
|
||||
"""Expands a basic dictionary with an accessors that are expected
|
||||
by Flask extensions and users for the session.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue