1
1
import { Transaction } from 'web3/eth/types'
2
2
3
- import { LoanOfferAPIInstance , LoanOfferModel , LoanMetadata , BaseLoanModel } from '../types'
3
+ import { LoanOfferAPIInstance , LoanOfferModel } from '../types'
4
4
import BaseService from './BaseService'
5
- import BaseLoanService from './BaseLoanService' ;
5
+ import BaseLoanService from './BaseLoanService'
6
6
7
7
export default class LoanOffer extends BaseLoanService implements LoanOfferAPIInstance {
8
8
constructor ( token : string , apiUrl ?: string ) {
9
- super ( '/offer' , token , apiUrl )
9
+ super ( '/offer' , token , apiUrl )
10
10
}
11
11
12
12
public async create ( lenderAddress : string , params : LoanOfferModel ) : Promise < Transaction > {
@@ -33,13 +33,7 @@ export default class LoanOffer extends BaseLoanService implements LoanOfferAPIIn
33
33
public async takeLoanOffer ( loanAddress : string , params : LoanOfferModel ) : Promise < Transaction > {
34
34
BaseService . checkAddressChecksum ( loanAddress )
35
35
36
- return await this . apiRequest (
37
- `/take/${ loanAddress } ` ,
38
- 'placing loan offer funds' ,
39
- loanAddress ,
40
- 'post' ,
41
- params
42
- )
36
+ return await this . apiRequest ( `/take/${ loanAddress } ` , 'placing loan offer funds' , loanAddress , 'post' , params )
43
37
}
44
38
45
39
public async getLoanData ( loanAddress : string ) : Promise < LoanOfferModel > {
@@ -67,5 +61,4 @@ export default class LoanOffer extends BaseLoanService implements LoanOfferAPIIn
67
61
68
62
return await Promise . all ( allDataPromises )
69
63
}
70
-
71
64
}
0 commit comments