checks.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:Harmonbot 作者: Harmon758 项目源码 文件源码
def is_voice_connected():

    def predicate(ctx):
        if not is_voice_connected_check(ctx):
            if is_server_owner_check(ctx) or utilities.get_permission(ctx, "join", id = ctx.message.author.id):
                raise errors.PermittedVoiceNotConnected
            else:
                raise errors.NotPermittedVoiceNotConnected
        return True

    return commands.check(predicate)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号