diff --git a/storagegroup/storagegroup.go b/storagegroup/storagegroup.go index 16214a18..d9d89dea 100644 --- a/storagegroup/storagegroup.go +++ b/storagegroup/storagegroup.go @@ -140,6 +140,7 @@ func (sg *StorageGroup) SetValidationDataHash(hash checksum.Checksum) { // See also SetExpirationEpoch. func (sg StorageGroup) ExpirationEpoch() uint64 { v2 := (storagegroup.StorageGroup)(sg) + // nolint:staticcheck return v2.GetExpirationEpoch() } @@ -148,6 +149,7 @@ func (sg StorageGroup) ExpirationEpoch() uint64 { // // See also ExpirationEpoch. func (sg *StorageGroup) SetExpirationEpoch(epoch uint64) { + // nolint:staticcheck (*storagegroup.StorageGroup)(sg).SetExpirationEpoch(epoch) } diff --git a/storagegroup/storagegroup_test.go b/storagegroup/storagegroup_test.go index 99520043..1328efc5 100644 --- a/storagegroup/storagegroup_test.go +++ b/storagegroup/storagegroup_test.go @@ -62,6 +62,7 @@ func TestStorageGroup_ReadFromV2(t *testing.T) { v2.SetMembers(generateOIDList()) size := v2.GetValidationDataSize() + // nolint:staticcheck epoch := v2.GetExpirationEpoch() mm := v2.GetMembers() hashV2 := v2.GetValidationHash() @@ -122,6 +123,7 @@ func TestStorageGroup_WriteToV2(t *testing.T) { require.Nil(t, v2.GetValidationHash()) require.Nil(t, v2.GetMembers()) require.Zero(t, v2.GetValidationDataSize()) + // nolint:staticcheck require.Zero(t, v2.GetExpirationEpoch()) }) @@ -132,7 +134,7 @@ func TestStorageGroup_WriteToV2(t *testing.T) { ) x.WriteToV2(&v2) - + // nolint:staticcheck require.Equal(t, x.ExpirationEpoch(), v2.GetExpirationEpoch()) require.Equal(t, x.ValidationDataSize(), v2.GetValidationDataSize())