fixed demo mode

This commit is contained in:
mdipierro
2013-10-07 09:17:51 -05:00
parent 961d143f7d
commit 5f34193ac7
2 changed files with 6 additions and 1 deletions

View File

@@ -1 +1 @@
Version 2.7.2-stable+timestamp.2013.10.07.08.39.32
Version 2.7.2-stable+timestamp.2013.10.07.09.16.58

View File

@@ -8,6 +8,7 @@ from gluon.fileutils import read_file
# ## make sure administrator is on localhost or https
# ###########################################################
http_host = request.env.http_host.split(':')[0]
if request.env.web2py_runtime_gae:
@@ -145,6 +146,10 @@ elif session.is_mobile == 'false':
else:
is_mobile = request.user_agent().is_mobile
if DEMO_MODE:
session.authorized = True
session.forget()
if request.controller == "webservices":
basic = request.env.http_authorization
if not basic or not basic[:6].lower() == 'basic ':