code: def pass_community(f):
      
      @wraps(f)
      def inner(community_id, *args, **kwargs):
          c = Community.get(community_id)
          if c is None:
              abort(404)
          return f(c, *args, **kwargs)
      return inner
docs: Decorator to pass community.