Skip to content

Commit

Permalink
revert: header support for v2
Browse files Browse the repository at this point in the history
Because it will be added in
celestiaorg#3589
  • Loading branch information
rootulp committed Aug 1, 2024
1 parent 2a8d98a commit 79d8458
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 72 deletions.
11 changes: 3 additions & 8 deletions header/header.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
core "github.com/tendermint/tendermint/types"

v1 "github.com/celestiaorg/celestia-app/v2/pkg/appconsts/v1"
v2 "github.com/celestiaorg/celestia-app/v2/pkg/appconsts/v2"
"github.com/celestiaorg/celestia-app/v2/pkg/da"
libhead "github.com/celestiaorg/go-header"
"github.com/celestiaorg/rsmt2d"
Expand Down Expand Up @@ -115,13 +114,9 @@ func (eh *ExtendedHeader) Validate() error {
return fmt.Errorf("ValidateBasic error on RawHeader at height %d: %w", eh.Height(), err)
}

if eh.RawHeader.Version.App != v1.Version && eh.RawHeader.Version.App != v2.Version {
return fmt.Errorf(
"app version mismatch, expected: %d or %d, got %d",
v1.Version,
v2.Version,
eh.RawHeader.Version.App,
)
if eh.RawHeader.Version.App != v1.Version {
return fmt.Errorf("app version mismatch, expected: %d, got %d", v1.Version,
eh.RawHeader.Version.App)
}

err = eh.Commit.ValidateBasic()
Expand Down
64 changes: 0 additions & 64 deletions header/headertest/validate_test.go

This file was deleted.

0 comments on commit 79d8458

Please sign in to comment.