Permalink
Browse files

Updating handler ofr py2.7

  • Loading branch information...
1 parent 7535b6e commit afc8d13122ff40a1a35d8b492d938e03af97412c @ebidel ebidel committed Sep 4, 2012
Showing with 3 additions and 3 deletions.
  1. +1 −1 echo.py
  2. +2 −2 main.py
View
2 echo.py
@@ -14,7 +14,7 @@
# limitations under the License.
#
-__author__ = ('ericbidelman@html5rocks.com (Eric Bidelman)')
+__author__ = 'ericbidelman@html5rocks.com (Eric Bidelman)'
import webapp2
View
4 main.py
@@ -88,7 +88,7 @@ def is_awesome_mobile_device(self):
return browser.find('Android') != -1 or browser.find('iPhone') != -1
def get_toc(self, path):
- # Only have TOC on tutorial pages.
+ # Only have TOC on tutorial pages. Don't do work for others.
if not (re.search('/tutorials', path) or re.search('/mobile', path)):
return ''
@@ -936,5 +936,5 @@ def handle_500(request, response, exception):
app = webapp2.WSGIApplication(routes, debug=settings.DEBUG)
app.error_handlers[404] = handle_404
-if settings.PROD and settings.DEBUG:
+if settings.PROD and not settings.DEBUG:
app.error_handlers[500] = handle_500

0 comments on commit afc8d13

Please sign in to comment.