original_docstring: Check if user has 'cataloging_admin' permissions for all 'collections'.
docstring: Check if user has 'cataloging_admin' permissions for all 'collections'.
docstring_tokens: Check if user has ' cataloging_admin ' permissions for all ' collections ' .
code: def is_cataloging_admin_for(self, *collections):
          """Check if user has 'cataloging_admin' permissions for all 'collections'."""
          collections = set(collections)
          if not collections:
              return False  # Can't be cataloging admin for nothing
          admin_permission_collections = set(_.collection for _ in self.permissions
                                             if _.cataloging_admin)
          return collections.issubset(admin_permission_collections)
code_tokens: def is_cataloging_admin_for ( self , * collections ) : collections = set ( collections ) if not collections : return False admin_permission_collections = set ( _ . collection for _ in self . permissions if _ . cataloging_admin ) return collections . issubset ( admin_permission_collections )
short_docstring: Check if user has 'cataloging_admin' permissions for all 'collections'.
short_docstring_tokens: Check if user has ' cataloging_admin ' permissions for all ' collections ' .
comment: """Check if user has 'cataloging_admin' permissions for all 'collections'."""$SEP$# Can't be cataloging admin for nothing