Skip to content

Commit b05fb12

Browse files
authored
Merge pull request #89 from MinterTeam/dev
Dev
2 parents 0116899 + 45dc86d commit b05fb12

File tree

4 files changed

+3
-9
lines changed

4 files changed

+3
-9
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.12.6
1+
2.12.7

database/db.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ CREATE INDEX pool_trades_transaction_id_index ON liquidity_pool_trades USING btr
277277
CREATE TABLE validator_bans
278278
(
279279
validator_id bigint not null references validators (id) on delete cascade,
280-
block_id bigint not null references blocks (id) on delete cascade
280+
block_id bigint not null
281281
);
282282
CREATE INDEX validator_bans_block_id_index ON validator_bans USING btree (block_id);
283283
CREATE INDEX validator_bans_validator_id_index ON validator_bans USING btree (validator_id);

events/service.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -169,12 +169,6 @@ func (s *Service) HandleEventResponse(blockHeight uint64, responseEvents *api_pb
169169
}
170170

171171
err = s.validatorRepository.SaveBan(ban)
172-
if err != nil {
173-
// temp solution
174-
time.Sleep(500 * time.Millisecond)
175-
err = s.validatorRepository.SaveBan(ban)
176-
}
177-
178172
if err != nil {
179173
s.logger.Error(err)
180174
}

models/validator_bans.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package models
22

33
type ValidatorBan struct {
4-
ValidatorId uint `json:"validator_id"`
4+
ValidatorId uint `json:"validator_id" pg:"rel:belongs-to"`
55
BlockId uint64 `json:"block_id"`
66
}

0 commit comments

Comments
 (0)