From 503fa62794ccca8e27cde99f3fbabf41adad5f3f Mon Sep 17 00:00:00 2001 From: René 'Necoro' Neumann Date: Thu, 29 Feb 2024 10:54:32 +0100 Subject: Replace util.Contains with slices.Contains --- internal/imap/connection.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'internal/imap') diff --git a/internal/imap/connection.go b/internal/imap/connection.go index 8c0f59c..201ca7d 100644 --- a/internal/imap/connection.go +++ b/internal/imap/connection.go @@ -3,6 +3,7 @@ package imap import ( "errors" "fmt" + "slices" "strings" "time" @@ -11,7 +12,6 @@ import ( imapClient "github.com/emersion/go-imap/client" "github.com/Necoro/feed2imap-go/pkg/log" - "github.com/Necoro/feed2imap-go/pkg/util" ) type client struct { @@ -125,7 +125,7 @@ func (conn *connection) ensureFolder(folder Folder) error { } switch { - case found == 0 || (found == 1 && util.Contains(mbox.Attributes, imap.NoSelectAttr)): + case found == 0 || (found == 1 && slices.Contains(mbox.Attributes, imap.NoSelectAttr)): return conn.createFolder(folder.str) case found == 1: conn.mailboxes.add(mbox) -- cgit v1.2.3-70-g09d2