Skip to content

Commit

Permalink
Merge pull request #138 from FyLMartin/master
Browse files Browse the repository at this point in the history
DateTimeRecognizerExtension does not return dates without times
  • Loading branch information
cleemullins authored Feb 16, 2018
2 parents 00663cc + e2e4fb5 commit e96813d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion samples/AlarmBot-Cards/DateTimeRecognizerExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public static IList<DateTime> GetDateTimes(this BotContext context)
return results.Where(result =>
{
var subType = result.TypeName.Split('.').Last();
return subType.Contains("time") && !subType.Contains("range");
return (subType.Contains("date") || subType.Contains("time")) && !subType.Contains("range");
})
.Select(result =>
{
Expand Down
2 changes: 1 addition & 1 deletion samples/AlarmBot/DateTimeRecognizerExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public static IList<DateTime> GetDateTimes(this BotContext context)
return results.Where(result =>
{
var subType = result.TypeName.Split('.').Last();
return subType.Contains("time") && !subType.Contains("range");
return (subType.Contains("date") || subType.Contains("time")) && !subType.Contains("range");
})
.Select(result =>
{
Expand Down

0 comments on commit e96813d

Please sign in to comment.