Skip to content

Commit e7fd412

Browse files
committed
Allow-warn timestamp of type Date
1 parent 33c6749 commit e7fd412

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/core/src/reducers/createActivitiesReducer.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,10 @@ function getSequenceIdOrDeriveFromTimestamp(
7575

7676
if (typeof timestamp === 'string') {
7777
return +new ponyfill.Date(timestamp);
78+
} else if ((timestamp as any) instanceof ponyfill.Date) {
79+
console.warn('botframework-webchat: "timestamp" must be of type string, instead of Date.');
80+
81+
return +timestamp;
7882
}
7983

8084
return undefined;

0 commit comments

Comments
 (0)