Skip to content

Commit

Permalink
sqlite: use contract ID for formation set
Browse files Browse the repository at this point in the history
  • Loading branch information
n8maninger committed Mar 23, 2023
1 parent 49aef7c commit ef6cdcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion persist/sqlite/contracts.go
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ func (s *Store) ContractAction(height uint64, contractFn func(types.FileContract
// contract formation.
func (s *Store) ContractFormationSet(id types.FileContractID) ([]types.Transaction, error) {
var buf []byte
err := s.queryRow(`SELECT formation_txn_set FROM contracts WHERE id=$1;`, sqlHash256(id)).Scan(&buf)
err := s.queryRow(`SELECT formation_txn_set FROM contracts WHERE contract_id=$1;`, sqlHash256(id)).Scan(&buf)
if err != nil {
return nil, fmt.Errorf("failed to query formation txn set: %w", err)
}
Expand Down

0 comments on commit ef6cdcf

Please sign in to comment.