From 61c7ce857e8cbae58a8718da9fabe7163d6ca79b Mon Sep 17 00:00:00 2001 From: Josh Date: Tue, 9 Mar 2021 07:50:37 -0800 Subject: [PATCH] fix: vote timestamp is nullable (#15774) --- explorer/src/components/instruction/vote/types.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/explorer/src/components/instruction/vote/types.ts b/explorer/src/components/instruction/vote/types.ts index 42de4e47b..d31669db7 100644 --- a/explorer/src/components/instruction/vote/types.ts +++ b/explorer/src/components/instruction/vote/types.ts @@ -1,6 +1,14 @@ /* eslint-disable @typescript-eslint/no-redeclare */ -import { array, number, optional, pick, string, StructType } from "superstruct"; +import { + array, + nullable, + number, + optional, + pick, + string, + StructType, +} from "superstruct"; import { Pubkey } from "validators/pubkey"; export type InitializeInfo = StructType; @@ -32,7 +40,7 @@ export const VoteInfo = pick({ vote: pick({ hash: string(), slots: array(number()), - timestamp: optional(number()), + timestamp: optional(nullable(number())), }), });