Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
mask-pp committed Sep 7, 2023
1 parent 3fb5a9e commit e10bfcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/controller/l2watcher/l2_contracts.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ func newL2Contracts(l2chainURL string, db *gorm.DB, cfg *config.Gateway) (*l2Con
}

func (l2 *l2Contracts) initWithdraw(db *gorm.DB) error {
tx := db.Where("type = ? AND msg_proof != ''", orm.L2SentMessage)
tx := db.Where("type = ? AND msg_proof != ''", orm.L2SentMessage).Order("number DESC")
var msg orm.L2MessengerEvent
err := tx.Last(&msg).Error
if err != nil && err.Error() != gorm.ErrRecordNotFound.Error() {
Expand Down

0 comments on commit e10bfcf

Please sign in to comment.