This commit is contained in:
Gabo Gilabert 2019-10-17 20:27:04 -04:00
Родитель ce427833d5
Коммит 072e688e6a
4 изменённых файлов: 13 добавлений и 3 удалений

Просмотреть файл

@ -6,6 +6,7 @@
<Rule Id="UseAsyncSuffix" Action="Error" />
<Rule Id="UseConfigureAwait" Action="Error" />
</Rules>
<Rules AnalyzerId="Microsoft.CodeAnalysis.CSharp.Features" RuleNamespace="Microsoft.CodeAnalysis.CSharp.Features">
<Rule Id="IDE0003" Action="None" />
</Rules>
@ -186,6 +187,7 @@
<Rule Id="SA1649" Action="Error" />
<Rule Id="SA1651" Action="Error" />
</Rules>
<Rules AnalyzerId="Microsoft.CodeQuality.Analyzers" RuleNamespace="Microsoft.CodeQuality.Analyzers">
<Rule Id="CA1062" Action="None" /> <!-- ValidateArgumentsOfPublicMethods -->
</Rules>

Просмотреть файл

@ -38,7 +38,7 @@ namespace Microsoft.Bot.Builder.Teams
var invokeResponse = await OnInvokeActivityAsync(new DelegatingTurnContext<IInvokeActivity>(turnContext), cancellationToken).ConfigureAwait(false);
if (invokeResponse != null)
{
await turnContext.SendActivityAsync(new Activity { Value = invokeResponse, Type = ActivityTypesEx.InvokeResponse }).ConfigureAwait(false);
await turnContext.SendActivityAsync(new Activity { Value = invokeResponse, Type = ActivityTypesEx.InvokeResponse }, cancellationToken).ConfigureAwait(false);
}
break;

Просмотреть файл

@ -69,9 +69,8 @@ namespace Microsoft.Bot.Builder.Teams
private static ITeamsConnectorClient GetTeamsConnectorClient(ITurnContext turnContext)
{
var connectorClient = GetConnectorClient(turnContext);
if (connectorClient is ConnectorClient)
if (connectorClient is ConnectorClient connectorClientImpl)
{
var connectorClientImpl = (ConnectorClient)connectorClient;
return new TeamsConnectorClient(connectorClientImpl.BaseUri, connectorClientImpl.Credentials, connectorClientImpl.HttpClient);
}
else

Просмотреть файл

@ -24,18 +24,27 @@ namespace Microsoft.Bot.Builder.TestBot.Json
/// <summary>
/// Gets or sets memory path to bind to arg1 (ex: conversation.width).
/// </summary>
/// <value>
/// Memory path to bind to arg1 (ex: conversation.width).
/// </value>
[JsonProperty("arg1")]
public string Arg1 { get; set; }
/// <summary>
/// Gets or sets memory path to bind to arg2 (ex: conversation.height).
/// </summary>
/// <value>
/// Memory path to bind to arg2 (ex: conversation.height).
/// </value>
[JsonProperty("arg2")]
public string Arg2 { get; set; }
/// <summary>
/// Gets or sets caller's memory path to store the result of this step in (ex: conversation.area).
/// </summary>
/// <value>
/// Caller's memory path to store the result of this step in (ex: conversation.area).
/// </value>
[JsonProperty("resultProperty")]
public string ResultProperty { get; set; }