From 80fabe7221cbbe8bc99316af6adfd6e51187e294 Mon Sep 17 00:00:00 2001 From: chirabski Date: Sat, 10 Feb 2024 20:50:17 +0100 Subject: [PATCH] [DEV] - add omitempty in type for pdf and image --- block.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block.go b/block.go index a19501e..6bf22eb 100644 --- a/block.go +++ b/block.go @@ -438,7 +438,7 @@ type ImageBlock struct { type Image struct { Caption []RichText `json:"caption,omitempty"` - Type FileType `json:"type"` + Type FileType `json:"type,omitempty"` File *FileObject `json:"file,omitempty"` External *FileObject `json:"external,omitempty"` } @@ -519,7 +519,7 @@ type PdfBlock struct { type Pdf struct { Caption []RichText `json:"caption,omitempty"` - Type FileType `json:"type"` + Type FileType `json:"type,omitempty"` File *FileObject `json:"file,omitempty"` External *FileObject `json:"external,omitempty"` }