Table of Contents

Method UseTwoFactorAsync

Namespace
DisCatSharp.Extensions.TwoFactorCommands
Assembly
DisCatSharp.Extensions.TwoFactorCommands.dll

UseTwoFactorAsync(DiscordShardedClient, TwoFactorConfiguration?)

Enables TwoFactor module on all shards in this DiscordShardedClient.

public static Task<IReadOnlyDictionary<int, TwoFactorExtension>> UseTwoFactorAsync(this DiscordShardedClient client, TwoFactorConfiguration? cfg = null)

Parameters

client DiscordShardedClient

Client to enable TwoFactor for.

cfg TwoFactorConfiguration

TwoFactor configuration to use.

Returns

Task<IReadOnlyDictionary<int, TwoFactorExtension>>

A dictionary of created TwoFactorExtension, indexed by shard id.