Fix max-sequece key in fly (#491)

This commit is contained in:
ftocal 2023-07-03 15:58:34 -03:00 committed by GitHub
parent 2a92a93eb4
commit 4e8b43a598
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -43,7 +43,7 @@ func NewLastSequenceNotifier(c *redis.Client, prefix string) *LastSequenceNotifi
if prefix == "" { if prefix == "" {
prefix = "wormscan:vaa-max-sequence" prefix = "wormscan:vaa-max-sequence"
} else { } else {
prefix = fmt.Sprintf("%s-wormscan:vaa-max-sequence", prefix) prefix = fmt.Sprintf("%s:wormscan:vaa-max-sequence", prefix)
} }
return &LastSequenceNotifier{ return &LastSequenceNotifier{

View File

@ -12,7 +12,7 @@ func TestNewLastSequenceNotifier(t *testing.T) {
l := NewLastSequenceNotifier(nil, "mainnet-staging") l := NewLastSequenceNotifier(nil, "mainnet-staging")
assert.Equal(t, "mainnet-staging-wormscan:vaa-max-sequence", l.prefix) assert.Equal(t, "mainnet-staging:wormscan:vaa-max-sequence", l.prefix)
} }
func TestNewLastSequenceNotifierBackwardsCompat(t *testing.T) { func TestNewLastSequenceNotifierBackwardsCompat(t *testing.T) {
@ -33,5 +33,5 @@ func TestNewLastSequenceNotifierWithPrefix(t *testing.T) {
l := NewLastSequenceNotifier(nil, prefix) l := NewLastSequenceNotifier(nil, prefix)
assert.Equal(t, "mainnet-staging-wormscan:vaa-max-sequence", l.prefix) assert.Equal(t, "mainnet-staging:wormscan:vaa-max-sequence", l.prefix)
} }