1
0
mirror of https://github.com/oliverbooth/VpSharp synced 2024-11-10 06:15:41 +00:00

ConfigureAwait(false) on awaited tasks

This commit is contained in:
Oliver Booth 2022-11-30 18:57:57 +00:00
parent 189ef770eb
commit f846b43680
No known key found for this signature in database
GPG Key ID: 32A00B35503AF634

View File

@ -109,7 +109,7 @@ public sealed partial class VirtualParadiseClient
} }
} }
(reason, virtualParadiseObject) = await taskCompletionSource.Task; (reason, virtualParadiseObject) = await taskCompletionSource.Task.ConfigureAwait(false);
_objectCompletionSources.TryRemove(id, out _); _objectCompletionSources.TryRemove(id, out _);
if (virtualParadiseObject is not null) if (virtualParadiseObject is not null)
@ -182,7 +182,7 @@ public sealed partial class VirtualParadiseClient
var location = new Location(CurrentWorld!, position, rotation); var location = new Location(CurrentWorld!, position, rotation);
virtualParadiseObject.Location = location; virtualParadiseObject.Location = location;
virtualParadiseObject.Owner = await GetUserAsync(owner); virtualParadiseObject.Owner = await GetUserAsync(owner).ConfigureAwait(false);
return virtualParadiseObject; return virtualParadiseObject;
} }
} }