From 0536783b09d58f016aefe238091981f397c31278 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Mon, 15 Jan 2024 14:16:36 +0100 Subject: [PATCH] blockservice: remove deprecated NewWriteThrough function --- CHANGELOG.md | 1 + blockservice/blockservice.go | 8 -------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 734c89ebf..12ad5df7e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ The following emojis are used to highlight certain changes: ### Added - `blockservice` now has `ContextWithSession` and `EmbedSessionInContext` functions, which allows to embed a session in a context. Future calls to `BlockGetter.GetBlock`, `BlockGetter.GetBlocks` and `NewSession` will use the session in the context. +- `blockservice.NewWritethrough` deprecated function has been removed, instead you can do `blockservice.New(..., ..., WriteThrough())` like previously. ### Changed diff --git a/blockservice/blockservice.go b/blockservice/blockservice.go index 7733788ec..353be00f8 100644 --- a/blockservice/blockservice.go +++ b/blockservice/blockservice.go @@ -119,14 +119,6 @@ func New(bs blockstore.Blockstore, exchange exchange.Interface, opts ...Option) return service } -// NewWriteThrough creates a BlockService that guarantees writes will go -// through to the blockstore and are not skipped by cache checks. -// -// Deprecated: Use [New] with the [WriteThrough] option. -func NewWriteThrough(bs blockstore.Blockstore, exchange exchange.Interface) BlockService { - return New(bs, exchange, WriteThrough()) -} - // Blockstore returns the blockstore behind this blockservice. func (s *blockService) Blockstore() blockstore.Blockstore { return s.blockstore