From 57c7187e6da5f61c74acabec3c2c1f1c8b41f386 Mon Sep 17 00:00:00 2001 From: Eric Coissac Date: Tue, 31 Jan 2023 17:15:10 +0100 Subject: [PATCH] Patch the JSON header formater --- pkg/obiformats/fastseq_json_header.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/obiformats/fastseq_json_header.go b/pkg/obiformats/fastseq_json_header.go index f4d6481..c592d39 100644 --- a/pkg/obiformats/fastseq_json_header.go +++ b/pkg/obiformats/fastseq_json_header.go @@ -70,7 +70,7 @@ func ParseFastSeqJsonHeader(sequence *obiseq.BioSequence) { func FormatFastSeqJsonHeader(sequence *obiseq.BioSequence) string { annotations := sequence.Annotations() - if annotations != nil { + if annotations != nil && len(annotations) > 0 { text, err := goutils.JsonMarshal(sequence.Annotations()) if err != nil {