From 26fbd323d5bd63df5a859a6f21f81daa239190fe Mon Sep 17 00:00:00 2001 From: Softonik Date: Mon, 4 Mar 2024 02:24:19 +0300 Subject: [PATCH] =?UTF-8?q?=D0=A7=D0=B8=D1=81=D1=82=D0=BA=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/mlib/ktgo/storage.go | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pkg/mlib/ktgo/storage.go b/pkg/mlib/ktgo/storage.go index b805f12..61d5128 100644 --- a/pkg/mlib/ktgo/storage.go +++ b/pkg/mlib/ktgo/storage.go @@ -17,13 +17,12 @@ var ( ) func initStorage() { - l, _ := storage.NewStorage(BlockedListFileName) - blockLists = append(blockLists, l) - - l, _ = storage.NewStorage(BlockedListFileNameLocal) - blockLists = append(blockLists, l) - - l, _ = storage.NewStorage(BlockedListFileNameShared) + addList(BlockedListFileName) + addList(BlockedListFileNameLocal) + addList(BlockedListFileNameShared) +} +func addList(path string) { + l, _ := storage.NewStorage(path) blockLists = append(blockLists, l) }