From 0256959a358bb26b983c9d9496862b0fdf387621 Mon Sep 17 00:00:00 2001 From: Bjørn Erik Pedersen Date: Tue, 21 Jul 2020 17:59:03 +0200 Subject: resources/js: Add option for setting bundle format Fixes #7503 --- media/mediaType.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'media') diff --git a/media/mediaType.go b/media/mediaType.go index 8a2efc4a4..21d4ddca5 100644 --- a/media/mediaType.go +++ b/media/mediaType.go @@ -378,6 +378,11 @@ func DecodeTypes(mms ...map[string]interface{}) (Types, error) { return m, nil } +// IsZero reports whether this Type represents a zero value. +func (m Type) IsZero() bool { + return m.SubType == "" +} + // MarshalJSON returns the JSON encoding of m. func (m Type) MarshalJSON() ([]byte, error) { type Alias Type -- cgit v1.2.3