Table of Contents

Class RequireGroupAdminAttribute

Namespace
Signal.Application.Commands.Preconditions
Assembly
Signal.Application.dll

The sender must be an admin of the Signal group the command was sent in (queried live through IGroupService). Fails in direct messages.

public sealed class RequireGroupAdminAttribute : PreconditionAttribute
Inheritance
RequireGroupAdminAttribute
Inherited Members

Methods

CheckAsync(CommandContext, CancellationToken)

Checks whether the command may run.

public override ValueTask<PreconditionResult> CheckAsync(CommandContext context, CancellationToken cancellationToken)

Parameters

context CommandContext

The command context.

cancellationToken CancellationToken

Cancelled when the host shuts down.

Returns

ValueTask<PreconditionResult>

The check result.