Update hubs-api-guide-server.md

pull/9313/head
Rick Anderson 2018-10-29 15:06:26 -10:00 committed by GitHub
parent 76295af8a1
commit 66dd5a6683
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -298,8 +298,10 @@ To call client methods from the server, use the `Clients` property in a method i
[!code-csharp[Main](hubs-api-guide-server/samples/sample23.cs?highlight=5)] [!code-csharp[Main](hubs-api-guide-server/samples/sample23.cs?highlight=5)]
> [!NOTE] Invoking a client method is an asynchronous operation and returns a `Task`. Use `await` :
> Invoking a client method is an asynchronous operation and returns a `Task`. Use `await` to ensure you wait for the message to be sent. If an error occurs while sending the message, `await` will also allow you to catch that exception using a try-catch block.
* To ensure the message is sent without error.
* To enable catching and handling errors.
**JavaScript client using generated proxy** **JavaScript client using generated proxy**