Skip to content

Commit

Permalink
fix:add default value for gas fee cap (#221)
Browse files Browse the repository at this point in the history
  • Loading branch information
hunjixin authored and simlecode committed Jul 22, 2022
1 parent 177a960 commit f8aa412
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions models/mysql/shared_params.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ type mysqlSharedParams struct {
ID uint `gorm:"primary_key;column:id;type:SMALLINT(2) unsigned AUTO_INCREMENT;NOT NULL" json:"id"`

GasOverEstimation float64 `gorm:"column:gas_over_estimation;type:DOUBLE;NOT NULL"`
MaxFee mtypes.Int `gorm:"column:max_fee;type:varchar(256);NOT NULL"`
GasFeeCap mtypes.Int `gorm:"column:gas_fee_cap;type:varchar(256);NOT NULL"`
GasOverPremium float64 `gorm:"column:gas_over_premium;type:DOUBLE;NOT NULL;default:0;"`
MaxFee mtypes.Int `gorm:"column:max_fee;type:varchar(256);NOT NULL;default:0"`
GasFeeCap mtypes.Int `gorm:"column:gas_fee_cap;type:varchar(256);NOT NULL;default:0"`
GasOverPremium float64 `gorm:"column:gas_over_premium;type:DOUBLE;NOT NULL;default:0"`
SelMsgNum uint64 `gorm:"column:sel_msg_num;type:BIGINT(20) UNSIGNED;NOT NULL"`
}

Expand Down
6 changes: 3 additions & 3 deletions models/sqlite/shared_params.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ type sqliteSharedParams struct {
ID uint `gorm:"primary_key;column:id;type:INT unsigned AUTO_INCREMENT;NOT NULL" json:"id"`

GasOverEstimation float64 `gorm:"column:gas_over_estimation;type:REAL;NOT NULL"`
MaxFee mtypes.Int `gorm:"column:max_fee;type:varchar(256);NOT NULL"`
GasFeeCap mtypes.Int `gorm:"column:gas_fee_cap;type:varchar(256);NOT NULL"`
GasOverPremium float64 `gorm:"column:gas_over_premium;type:REAL;"`
MaxFee mtypes.Int `gorm:"column:max_fee;type:varchar(256);NOT NULL;default:0"`
GasFeeCap mtypes.Int `gorm:"column:gas_fee_cap;type:varchar(256);NOT NULL;default:0"`
GasOverPremium float64 `gorm:"column:gas_over_premium;type:REAL;NOT NULL;default:0"`

SelMsgNum uint64 `gorm:"column:sel_msg_num;type:UNSIGNED BIG INT;NOT NULL"`
}
Expand Down

0 comments on commit f8aa412

Please sign in to comment.