comparison bitsyblog/bitsyblog.py @ 74:2c219b788648

dont let handlers kill the blog
author Jeff Hammel <jhammel@mozilla.com>
date Wed, 15 Sep 2010 10:34:14 -0700
parents c9bab68d00ac
children c690198a2625
comparison
equal deleted inserted replaced
73:e6055bf127eb 74:2c219b788648
343 blog_entry = self.blog.post(user, now, body, privacy) 343 blog_entry = self.blog.post(user, now, body, privacy)
344 344
345 # fire event handlers 345 # fire event handlers
346 # XXX could be done asynchronously 346 # XXX could be done asynchronously
347 for handler in self.handlers: 347 for handler in self.handlers:
348 try:
348 handler(blog_entry, location) 349 handler(blog_entry, location)
350 except:
351 pass
349 352
350 # point the user at the post 353 # point the user at the post
351 return exc.HTTPSeeOther("Post blogged by bitsy", location=location) 354 return exc.HTTPSeeOther("Post blogged by bitsy", location=location)
352 355
353 def put(self, request): 356 def put(self, request):