File tree Expand file tree Collapse file tree 4 files changed +7
-5
lines changed Expand file tree Collapse file tree 4 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 1+ declare module '@blockcore/coininfo' ;
Original file line number Diff line number Diff line change 11{
22 "name" : " @blockcore/provider" ,
3- "version" : " 0.0.5 " ,
3+ "version" : " 0.0.6 " ,
44 "description" : " " ,
55 "type" : " module" ,
66 "exports" : " ./lib/index.js" ,
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ export class Provider implements EIP1193Provider {
2121 }
2222
2323 on ( event : string , callback : any ) {
24+ console . log ( event , callback ) ;
2425 // "accountsChanged"
2526 // "chainChanged"
2627 // "networkChanged"
@@ -88,16 +89,16 @@ export class Provider implements EIP1193Provider {
8889 } ,
8990 ] ;
9091 case 'requestPermissions' : //
91- break ;
92+ return null ;
9293 case 'getTransactionByHash' :
9394 return this . getBlockTransactionsByHash ( param0 . transactionHash ) ;
9495 case 'getBlockByHash' :
9596 return this . getBlockByHash ( param0 . blockHash ) ; // TODO: Add support for "includeTransactions".
9697 case 'getBlockByNumber' :
9798 return this . getBlockByIndex ( param0 . blockNumber ) ; // TODO: Add support for "includeTransactions".
99+ default :
100+ return null ;
98101 }
99-
100- console . log ( 'UNHANDLED METHOD!!' ) ;
101102 }
102103
103104 private async fetchText ( url : string ) : Promise < string > {
Original file line number Diff line number Diff line change 55 },
66 "include" : [
77 " src"
8- ],
8+ , " ambient.d.ts " ],
99 "ts-node" : {
1010 "transpileOnly" : true ,
1111 "files" : true ,
You can’t perform that action at this time.
0 commit comments