def METHOD_NAME(user, chat_message):
    """
    This predicate checks whether the given user can delete a given chat message
    :param user: The user who's permission should be checked
    :type user: ~django.contrib.auth.models.User
    :param chat_message: The requested chat message
    :type chat_message: ~integreat_cms.cms.models.chat.chat_message.ChatMessage
    :return: Whether or not ``user`` is allowed to delete ``chat_message``
    :rtype: bool
    """
    # Check if user has the permission to delete all chat messages
    if user.has_perm("cms.delete_chat_message"):
        return True
    # Normal users can only delete their own messages
    return user == chat_message.sender