Skip to content

Commit

Permalink
Fix name collisions.
Browse files Browse the repository at this point in the history
  • Loading branch information
msinkec committed Dec 7, 2023
1 parent 7da828f commit 1d67467
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/contracts/bsv20CouponBond.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
} from 'scrypt-ts'
import { RabinPubKey, RabinSig, RabinVerifier } from 'scrypt-ts-lib'

export type Investor = {
export type BondInvestor = {
emptySlot: boolean
pubKey: PubKey
forSale: boolean
Expand All @@ -31,7 +31,7 @@ export class Bsv20CouponBond extends BSV20V2 {
issuer: PubKey

@prop(true)
investors: FixedArray<Investor, typeof Bsv20CouponBond.N_INVESTORS>
investors: FixedArray<BondInvestor, typeof Bsv20CouponBond.N_INVESTORS>

@prop()
faceValue: bigint
Expand Down Expand Up @@ -70,7 +70,7 @@ export class Bsv20CouponBond extends BSV20V2 {
),
forSale: false,
price: 0n,
} as Investor,
} as BondInvestor,
10
)
this.faceValue = faceValue
Expand Down
8 changes: 4 additions & 4 deletions src/contracts/bsv20LendingPool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ import {
RabinVerifier,
} from 'scrypt-ts-lib'

export type Lender = {
export type PoolLender = {
emptySlot: boolean
pubKey: PubKey
amt: bigint
deadline: bigint
}

export type Borrower = {
export type PoolBorrower = {
emptySlot: boolean
pubKey: PubKey
amt: bigint
Expand All @@ -44,10 +44,10 @@ export class Bsv20LendingPool extends BSV20V2 {
static readonly N_BORROWERS = 10

@prop(true)
lenders: FixedArray<Lender, typeof Bsv20LendingPool.N_BORROWERS>
lenders: FixedArray<PoolLender, typeof Bsv20LendingPool.N_BORROWERS>

@prop(true)
borrowers: FixedArray<Borrower, typeof Bsv20LendingPool.N_BORROWERS>
borrowers: FixedArray<PoolBorrower, typeof Bsv20LendingPool.N_BORROWERS>

// Fixed interest rate of the loan.
// 1 = 1%
Expand Down

0 comments on commit 1d67467

Please sign in to comment.