Skip to content
This repository was archived by the owner on Dec 26, 2025. It is now read-only.

Add CancellationToken support to Async methods#146

Merged
chrissainty merged 1 commit intoBlazored:mainfrom
Kim-SSi:CancellationToken
Jun 13, 2021
Merged

Add CancellationToken support to Async methods#146
chrissainty merged 1 commit intoBlazored:mainfrom
Kim-SSi:CancellationToken

Conversation

@Kim-SSi
Copy link
Contributor

@Kim-SSi Kim-SSi commented May 31, 2021

No description provided.

@Kim-SSi
Copy link
Contributor Author

Kim-SSi commented Jun 1, 2021

The reason for this change is that I am using @implements IDisposable in components and want to be able to cancel the Async calls.

    private readonly CancellationTokenSource TokenSource = newCancellationTokenSource();

    public void Dispose()
    {
        TokenSource.Cancel();
    }

Copy link
Member

@chrissainty chrissainty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies for the delay getting to this @Kim-SSi. Everything looks good here, I'll get it merged.

@chrissainty chrissainty added the Maintenance General maintenance label Jun 13, 2021
@chrissainty chrissainty merged commit 5b9947f into Blazored:main Jun 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Maintenance General maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants