Table of Contents

Class DontAutoLoadAttribute

Namespace
Discord.Commands
Assembly
Discord.Net.Commands.dll

Prevents the marked module from being loaded automatically.

[AttributeUsage(AttributeTargets.Class, AllowMultiple = false, Inherited = true)]
public class DontAutoLoadAttribute : Attribute
Inheritance
DontAutoLoadAttribute
Inherited Members

Examples

[DontAutoLoad]
public class MyModule : ModuleBase<SocketCommandContext>
{
    // ...
}

Remarks

The attribute can be applied to a public class that inherits ModuleBase. By applying this attribute, AddModulesAsync will not discover and add the marked module to the CommandService.