File tree Expand file tree Collapse file tree 10 files changed +12
-12
lines changed Expand file tree Collapse file tree 10 files changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -165,7 +165,7 @@ export class CheckpointDB implements DB {
165
165
value !== undefined
166
166
? value instanceof Uint8Array
167
167
? value
168
- : unprefixedHexToBytes ( < string > value )
168
+ : unprefixedHexToBytes ( value as string )
169
169
: undefined
170
170
this . _cache ?. set ( keyHex , returnValue )
171
171
if ( this . hasCheckpoints ( ) ) {
@@ -250,7 +250,7 @@ export class CheckpointDB implements DB {
250
250
}
251
251
this . _stats . db . writes += 1
252
252
if ( op . type === 'put' && this . valueEncoding === ValueEncoding . String ) {
253
- convertedOp . value = bytesToUnprefixedHex ( < Uint8Array > convertedOp . value )
253
+ convertedOp . value = bytesToUnprefixedHex ( convertedOp . value as Uint8Array )
254
254
}
255
255
return convertedOp
256
256
} )
Original file line number Diff line number Diff line change @@ -158,7 +158,7 @@ export class Block {
158
158
* Returns a Array of the raw Bytes Arrays of this block, in order.
159
159
*/
160
160
raw ( ) : BlockBytes {
161
- const bytesArray = < BlockBytes > [
161
+ const bytesArray : BlockBytes = [
162
162
this . header . raw ( ) ,
163
163
this . transactions . map ( ( tx ) =>
164
164
tx . supports ( Capability . EIP2718TypedTransaction ) ? tx . serialize ( ) : tx . raw ( ) ,
Original file line number Diff line number Diff line change @@ -165,7 +165,7 @@ export class CheckpointDB implements DB {
165
165
value !== undefined
166
166
? value instanceof Uint8Array
167
167
? value
168
- : unprefixedHexToBytes ( < string > value )
168
+ : unprefixedHexToBytes ( value as string )
169
169
: undefined
170
170
this . _cache ?. set ( keyHex , returnValue )
171
171
if ( this . hasCheckpoints ( ) ) {
@@ -250,7 +250,7 @@ export class CheckpointDB implements DB {
250
250
}
251
251
this . _stats . db . writes += 1
252
252
if ( op . type === 'put' && this . valueEncoding === ValueEncoding . String ) {
253
- convertedOp . value = bytesToUnprefixedHex ( < Uint8Array > convertedOp . value )
253
+ convertedOp . value = bytesToUnprefixedHex ( convertedOp . value as Uint8Array )
254
254
}
255
255
return convertedOp
256
256
} )
Original file line number Diff line number Diff line change @@ -333,7 +333,7 @@ export class MerklePatriciaTrie {
333
333
let progress = 0
334
334
for ( let i = 0 ; i < partialPath . stack . length - 1 ; i ++ ) {
335
335
stack [ i ] = partialPath . stack [ i ]
336
- progress += stack [ i ] instanceof BranchMPTNode ? 1 : ( < ExtensionMPTNode > stack [ i ] ) . keyLength ( )
336
+ progress += stack [ i ] instanceof BranchMPTNode ? 1 : ( stack [ i ] as ExtensionMPTNode ) . keyLength ( )
337
337
}
338
338
this . DEBUG && this . debug ( `Target (${ targetKey . length } ): [${ targetKey } ]` , [ 'find_path' ] )
339
339
let result : Path | null = null
Original file line number Diff line number Diff line change @@ -351,7 +351,7 @@ export class FeeMarket1559Tx
351
351
}
352
352
353
353
sign ( privateKey : Uint8Array , extraEntropy : Uint8Array | boolean = false ) : FeeMarket1559Tx {
354
- return < FeeMarket1559Tx > Legacy . sign ( this , privateKey , extraEntropy )
354
+ return Legacy . sign ( this , privateKey , extraEntropy ) as FeeMarket1559Tx
355
355
}
356
356
357
357
public isSigned ( ) : boolean {
Original file line number Diff line number Diff line change @@ -325,7 +325,7 @@ export class AccessList2930Tx
325
325
}
326
326
327
327
sign ( privateKey : Uint8Array , extraEntropy : Uint8Array | boolean = false ) : AccessList2930Tx {
328
- return < AccessList2930Tx > Legacy . sign ( this , privateKey , extraEntropy )
328
+ return Legacy . sign ( this , privateKey , extraEntropy ) as AccessList2930Tx
329
329
}
330
330
331
331
isSigned ( ) : boolean {
Original file line number Diff line number Diff line change @@ -441,7 +441,7 @@ export class Blob4844Tx implements TransactionInterface<typeof TransactionType.B
441
441
}
442
442
443
443
sign ( privateKey : Uint8Array , extraEntropy : Uint8Array | boolean = false ) : Blob4844Tx {
444
- return < Blob4844Tx > Legacy . sign ( this , privateKey , extraEntropy )
444
+ return Legacy . sign ( this , privateKey , extraEntropy ) as Blob4844Tx
445
445
}
446
446
447
447
public isSigned ( ) : boolean {
Original file line number Diff line number Diff line change @@ -391,7 +391,7 @@ export class EOACode7702Tx implements TransactionInterface<typeof TransactionTyp
391
391
}
392
392
393
393
sign ( privateKey : Uint8Array , extraEntropy : Uint8Array | boolean = false ) : EOACode7702Tx {
394
- return < EOACode7702Tx > Legacy . sign ( this , privateKey , extraEntropy )
394
+ return Legacy . sign ( this , privateKey , extraEntropy ) as EOACode7702Tx
395
395
}
396
396
397
397
public isSigned ( ) : boolean {
Original file line number Diff line number Diff line change @@ -397,7 +397,7 @@ export class LegacyTx implements TransactionInterface<typeof TransactionType.Leg
397
397
}
398
398
399
399
sign ( privateKey : Uint8Array , extraEntropy : Uint8Array | boolean = false ) : LegacyTx {
400
- return < LegacyTx > Legacy . sign ( this , privateKey , extraEntropy )
400
+ return Legacy . sign ( this , privateKey , extraEntropy ) as LegacyTx
401
401
}
402
402
403
403
/**
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ export function withdrawalToBytesArray(withdrawal: Withdrawal | WithdrawalData):
44
44
? new Uint8Array ( )
45
45
: toType ( validatorIndex , TypeOutput . Uint8Array )
46
46
const addressBytes =
47
- address instanceof Address ? ( < Address > address ) . bytes : toType ( address , TypeOutput . Uint8Array )
47
+ address instanceof Address ? address . bytes : toType ( address , TypeOutput . Uint8Array )
48
48
49
49
const amountBytes =
50
50
toType ( amount , TypeOutput . BigInt ) === BIGINT_0
You can’t perform that action at this time.
0 commit comments