mirror of
https://github.com/chylex/Discord-History-Tracker.git
synced 2024-12-22 14:42:50 +01:00
13 lines
249 B
C#
13 lines
249 B
C#
using System;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace DHT.Utils.Tasks;
|
|
|
|
public static class TaskExtensions {
|
|
public static async Task WaitIgnoringCancellation(this Task task) {
|
|
try {
|
|
await task;
|
|
} catch (OperationCanceledException) {}
|
|
}
|
|
}
|