def builder_wrapper(thing): if isinstance(thing, Comment): p = thing.make_permalink_slow() f = thing._fullname w = Wrapped(thing) w.render_class = Message w.to_id = c.user._id w.was_comment = True w.permalink, w._fullname = p, f return w else: return ListingController.builder_wrapper(thing)
def builder_wrapper(thing): if isinstance(thing, Comment): p = thing.make_permalink_slow() f = thing._fullname w = Wrapped(thing) w.render_class = Message w.to_id = c.user._id w.was_comment = True w.permalink, w._fullname = p, f else: w = ListingController.builder_wrapper(thing) return w
def builder_wrapper(thing): if isinstance(thing, Comment): p = thing.permalink f = thing._fullname thing.__class__ = Message w = Wrapped(thing) w.to_id = c.user._id w.subject = 'comment reply' w.was_comment = True w.permalink, w._fullname = p, f return w else: return ListingController.builder_wrapper(thing)