Skip to content

Commit 966cfc7

Browse files
Copilotjulienrbrt
andcommitted
Refine pruner checks and docs
Co-authored-by: julienrbrt <29894366+julienrbrt@users.noreply.github.com>
1 parent 80e4317 commit 966cfc7

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

block/internal/pruner/pruner.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -125,10 +125,7 @@ func (p *Pruner) pruneOnce(ctx context.Context) error {
125125
}
126126

127127
target := height - p.retention
128-
if target < p.lastPruned {
129-
return nil
130-
}
131-
if target == p.lastPruned {
128+
if target <= p.lastPruned {
132129
return nil
133130
}
134131

execution/evm/execution.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,7 @@ func NewEngineExecutionClient(
268268

269269
// PruneExecMeta removes execution metadata at the given height.
270270
// It is used by the block pruner to delete historical exec meta entries.
271+
// Returns nil if no store is configured.
271272
func (c *EngineClient) PruneExecMeta(ctx context.Context, height uint64) error {
272273
if c.store == nil {
273274
return nil

0 commit comments

Comments
 (0)