Skip to content

Commit

Permalink
Merge branch 'master' into fix-686-where-builder
Browse files Browse the repository at this point in the history
  • Loading branch information
chris-4chain authored Mar 27, 2024
2 parents cbaed70 + 5d65e41 commit 35dd16e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions engine/model_paymail_addresses.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ type PaymailAddress struct {
Avatar string `json:"avatar" toml:"avatar" yaml:"avatar" gorm:"<-;type:text;comment:This is avatar url" bson:"avatar"` // This is the url of the user (public profile)

ExternalXpubKey string `json:"external_xpub_key" toml:"external_xpub_key" yaml:"external_xpub_key" gorm:"<-:create;type:varchar(512);index;comment:This is full xPub for external use, encryption optional" bson:"external_xpub_key"` // PublicKey hex encoded
ExternalXpubKeyNum uint32 `json:"external_xpub_num" toml:"external_xpub_num" yaml:"external_xpub_num" gorm:"<-;type:int not null;default:0;comment:Derivation number used to generate ExternalXpubKey:external_xpub_num"`
PubKeyNum uint32 `json:"pubkey_num" toml:"pubkey_num" yaml:"pubkey_num" gorm:"<-;type:int not null;default:0;comment:Derivation number use to create PKI public key:pubkey_num"`
XpubDerivationSeq uint32 `json:"xpub_derivation_seq" toml:"xpub_derivation_seq" yaml:"xpub_derivation_seq" gorm:"<-;type:int not null;default:0;comment:The index derivation number use to generate new external xpub child keys and rotate PubKey:xpub_derivation_seq"`
ExternalXpubKeyNum uint32 `json:"external_xpub_num" toml:"external_xpub_num" yaml:"external_xpub_num" gorm:"<-;type:int;default:0;comment:Derivation number used to generate ExternalXpubKey:external_xpub_num"`
PubKeyNum uint32 `json:"pubkey_num" toml:"pubkey_num" yaml:"pubkey_num" gorm:"<-;type:int;default:0;comment:Derivation number use to create PKI public key:pubkey_num"`
XpubDerivationSeq uint32 `json:"xpub_derivation_seq" toml:"xpub_derivation_seq" yaml:"xpub_derivation_seq" gorm:"<-;type:int;default:0;comment:The index derivation number use to generate new external xpub child keys and rotate PubKey:xpub_derivation_seq"`

// Private fields
externalXpubKeyDecrypted string
Expand Down
4 changes: 2 additions & 2 deletions engine/model_xpubs.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ type Xpub struct {
// Model specific fields
ID string `json:"id" toml:"id" yaml:"id" gorm:"<-:create;type:char(64);primaryKey;comment:This is the sha256(xpub) hash" bson:"_id"`
CurrentBalance uint64 `json:"current_balance" toml:"current_balance" yaml:"current_balance" gorm:"<-;comment:The current balance of unspent satoshis" bson:"current_balance"`
NextInternalNum uint32 `json:"next_internal_num" toml:"next_internal_num" yaml:"next_internal_num" gorm:"<-;type:int not null;default:0;comment:The index derivation number use to generate NEXT internal xPub (internal xPub are used for change destinations)" bson:"next_internal_num"`
NextExternalNum uint32 `json:"next_external_num" toml:"next_external_num" yaml:"next_external_num" gorm:"<-;type:int not null;default:0;comment:The index derivation number use to generate NEXT external xPub (external xPub are used for address destinations)" bson:"next_external_num"`
NextInternalNum uint32 `json:"next_internal_num" toml:"next_internal_num" yaml:"next_internal_num" gorm:"<-;type:int;default:0;comment:The index derivation number use to generate NEXT internal xPub (internal xPub are used for change destinations)" bson:"next_internal_num"`
NextExternalNum uint32 `json:"next_external_num" toml:"next_external_num" yaml:"next_external_num" gorm:"<-;type:int;default:0;comment:The index derivation number use to generate NEXT external xPub (external xPub are used for address destinations)" bson:"next_external_num"`

destinations []Destination `gorm:"-" bson:"-"` // json:"destinations,omitempty"
}
Expand Down

0 comments on commit 35dd16e

Please # to comment.