frostfs-node/pkg/core/version/version.go
Stanislav Bogatyrev cb016d53a6 [#1] Fix comments and error messages
Signed-off-by: Stanislav Bogatyrev <s.bogatyrev@yadro.com>
2023-02-06 17:41:14 +03:00

17 lines
344 B
Go

package version
import (
"github.com/TrueCloudLab/frostfs-sdk-go/version"
)
// IsValid checks if Version is not earlier than the genesis version of the FrostFS.
func IsValid(v version.Version) bool {
const (
startMajor = 2
startMinor = 7
)
mjr := v.Major()
return mjr > startMajor || mjr == startMajor && v.Minor() >= startMinor
}