From 4d930c0c8cb585979798fac2bb254f991faa62fb Mon Sep 17 00:00:00 2001 From: Gabriel Arakaki Giovanini Date: Mon, 26 Jun 2023 22:26:10 +0200 Subject: feat: Add initial user setup --- pkg/components/media/model.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'pkg/components/media') diff --git a/pkg/components/media/model.go b/pkg/components/media/model.go index 0e17e92..1962a23 100644 --- a/pkg/components/media/model.go +++ b/pkg/components/media/model.go @@ -2,6 +2,7 @@ package media import ( "context" + "strings" "time" ) @@ -57,3 +58,7 @@ type ( CreateEXIF(context.Context, uint, *MediaEXIF) error } ) + +func (m *Media) IsVideo() bool { + return strings.HasPrefix(m.MIMEType, "video") +} -- cgit v1.2.3