mirror of
https://github.com/facebook/sapling.git
synced 2024-10-08 07:49:11 +03:00
configitems: register the 'web.cache' config
This commit is contained in:
parent
4d84c5f2d5
commit
c71a63f860
@ -727,6 +727,9 @@ coreconfigitem('web', 'allow_push',
|
||||
coreconfigitem('web', 'allowzip',
|
||||
default=None,
|
||||
)
|
||||
coreconfigitem('web', 'cache',
|
||||
default=True,
|
||||
)
|
||||
coreconfigitem('web', 'accesslog',
|
||||
default='-',
|
||||
)
|
||||
|
@ -436,7 +436,7 @@ class hgweb(object):
|
||||
|
||||
# Don't enable caching if using a CSP nonce because then it wouldn't
|
||||
# be a nonce.
|
||||
if rctx.configbool('web', 'cache', True) and not rctx.nonce:
|
||||
if rctx.configbool('web', 'cache') and not rctx.nonce:
|
||||
caching(self, req) # sets ETag header or raises NOT_MODIFIED
|
||||
if cmd not in webcommands.__all__:
|
||||
msg = 'no such method: %s' % cmd
|
||||
|
Loading…
Reference in New Issue
Block a user