Daniel Liu
a14e9416fa
all: fix staticcheck warning SA4010: append result never used
2024-10-31 10:06:04 +08:00
Daniel Liu
6dbf0d26e9
Merge pull request #698 from gzliudan/fix-st1008
...
all: fix staticcheck warning ST1008: error should be last return value
2024-10-31 10:05:04 +08:00
Daniel Liu
c36642a0e1
all: fix staticcheck warning ST1008: error should be last return value
2024-10-31 09:51:47 +08:00
Daniel Liu
f81cb2bf55
Merge pull request #688 from gzliudan/fix-nil-deref
...
fix nil issues reported by nilness and staticcheck
2024-10-31 09:31:14 +08:00
Daniel Liu
60fedfed83
fix staticcheck SA5011: possible nil pointer dereference
2024-10-31 09:01:12 +08:00
Daniel Liu
5f66fb5de0
fix tautological condition: nil == nil
2024-10-31 09:01:12 +08:00
Daniel Liu
371c3b6874
fix tautological condition: non-nil != nil
2024-10-31 09:01:12 +08:00
Daniel Liu
c688f4b24c
fix panic with nil value
2024-10-31 09:01:12 +08:00
Daniel Liu
2306ceafb2
fix impossible condition: nil != nil
2024-10-31 09:01:12 +08:00
Daniel Liu
6ed8d399c2
fix nil dereference in field selection
2024-10-31 09:01:12 +08:00
benjamin202410
6b6cf4b988
Merge pull request #716 from XinFinOrg/merge-master-back-to-dev-upgrade
...
Merge master back to dev upgrade
2024-10-30 17:02:12 -07:00
liam.icheng.lai
59a7eb1f9f
resolve conflict from master
2024-10-30 16:47:26 -07:00
Daniel Liu
dd7b9b1dea
Merge pull request #715 from gzliudan/fix-sa5007
...
XDCxDAO: fix staticcheck warning SA5007: infinite recursive call
2024-10-30 21:16:31 +08:00
Daniel Liu
381226c506
XDCxDAO: fix staticcheck warning SA5007: infinite recursive call
2024-10-30 21:16:02 +08:00
Daniel Liu
3f0e1576ab
Merge pull request #714 from gzliudan/fix-sa6005
...
core: fix staticcheck warning SA6005: should use strings.EqualFold
2024-10-30 21:14:22 +08:00
Daniel Liu
212daafe17
core: fix staticcheck warning SA6005: should use strings.EqualFold
2024-10-30 21:13:58 +08:00
Daniel Liu
dc562d4ab1
Merge pull request #713 from gzliudan/fix-sa9004
...
compression/rle: fix staticcheck warning SA9004: only the first constant has an explicit type
2024-10-30 21:12:46 +08:00
Daniel Liu
29c9c5808a
compression/rle: fix staticcheck warning SA9004: constant has no explicit type
2024-10-30 21:12:32 +08:00
Daniel Liu
8f79376ef7
Merge pull request #712 from gzliudan/fix-sa9009
...
crypto/bn256: fix staticcheck warning SA9009: ineffectual go compiler directive
2024-10-30 21:11:16 +08:00
Daniel Liu
95f8abb765
crypto/bn256: fix staticcheck warning SA9009: ineffectual compiler directive
2024-10-30 21:10:45 +08:00
Daniel Liu
b4fe994eff
Merge pull request #711 from gzliudan/fix-st1012
...
XDPoSChain, ethclient: fix staticcheck warning ST1012: rename NotFound to ErrNotFound
2024-10-30 21:07:33 +08:00
Daniel Liu
1329edfe5f
XDPoSChain, ethclient: fix staticcheck warning ST1012: rename NotFound to ErrNotFound
2024-10-30 21:07:05 +08:00
Daniel Liu
95f383d586
Merge pull request #710 from gzliudan/fix-s1001
...
common: fix staticcheck warning S1001: replace loop with copy
2024-10-30 21:05:53 +08:00
Daniel Liu
5b0b5b52c7
common: fix staticcheck warning S1001: replace loop with copy
2024-10-30 21:05:15 +08:00
Daniel Liu
5df53e81ed
Merge pull request #709 from gzliudan/fix-s1002
...
core, XDCxlending/lendingstate: fix staticcheck warning S1002: omit comparison to bool constant
2024-10-30 21:03:32 +08:00
Daniel Liu
181b23a767
core, XDCxlending/lendingstate: fix staticcheck warning S1002: omit comparison to bool constant
2024-10-30 21:02:41 +08:00
benjamin202410
118ccd08d5
cherry pick epoch api from dev-upgrade ( #699 )
...
* cherry-pick-epoch-api
2024-10-29 01:36:22 -07:00
Daniel Liu
57e40f59d7
Merge pull request #701 from gzliudan/fix-st1019
...
all: fix staticcheck warning ST1019: import package twice
2024-10-28 18:34:29 +08:00
Daniel Liu
a5bc0baba9
all: fix staticcheck warning ST1019: import package twice
2024-10-28 17:45:19 +08:00
Daniel Liu
efe041a684
Merge pull request #697 from gzliudan/fix-s1034
...
XDCxDAO: fix staticcheck warning S1034: use result of type assertion to simplify cases
2024-10-28 15:17:01 +08:00
Daniel Liu
9c1492189d
XDCxDAO: fix staticcheck warning S1034: use result of type assertion to simplify cases
2024-10-28 15:16:22 +08:00
wgr523
71b9005f34
feat: add api xdpos_getBlockInfoByEpochNum ( #674 )
...
* feat: add api xdpos_getBlockInfoByEpochNum
* feat: add cache round2epochBlockInfo
* fix: round2epochBlockInfo contains round now
* feat: binary search in GetBlockByEpochNumber
* fix: change some code back, refine style
2024-10-28 00:14:30 -07:00
Daniel Liu
f12e92bbc7
Merge pull request #696 from gzliudan/fix-sa1006
...
all: fix staticcheck warning SA1006
2024-10-28 15:14:08 +08:00
Daniel Liu
4709ca3f13
all: fix staticcheck warning SA1006
2024-10-28 15:13:21 +08:00
Daniel Liu
7b5104576e
Merge pull request #686 from gzliudan/fix-st1006
...
all: fix staticcheck warning ST1006
2024-10-25 21:31:27 +08:00
Daniel Liu
fbecb8c5a5
all: fix staticcheck warning ST1006: don't use generic name self
...
The name of a method’s receiver should be a reflection of its identity;
often a one or two letter abbreviation of its type suffices (such as
“c” or “cl” for “Client”). Don’t use generic names such as “me”, “this”
or “self”, identifiers typical of object-oriented languages that place
more emphasis on methods as opposed to functions. The name need not be
as descriptive as that of a method argument, as its role is obvious and
serves no documentary purpose. It can be very short as it will appear
on almost every line of every method of the type; familiarity admits
brevity. Be consistent, too: if you call the receiver “c” in one method,
don’t call it “cl” in another.
2024-10-25 21:30:54 +08:00
Daniel Liu
acb973ab97
Merge pull request #695 from gzliudan/fix-sa1012
...
fix staticcheck warning SA1012: pass nil Context to function
2024-10-25 19:34:09 +08:00
Daniel Liu
dd6822bc3c
internal/ethapi, contracts/trc21issuer: fix staticcheck warning SA1012: pass nil Context
2024-10-25 18:29:08 +08:00
Daniel Liu
b68b9c64ea
Merge pull request #685 from gzliudan/emptyroot
...
all: use unified emptyRootHash and emptyCodeHash
2024-10-25 15:28:51 +08:00
Daniel Liu
87a6b5f4c3
Merge pull request #689 from gzliudan/fix-st1005
...
all: fix staticcheck warning ST1005
2024-10-25 15:28:07 +08:00
Daniel Liu
bd4bb14b5e
Merge pull request #692 from gzliudan/fix-sa4006
...
all: fix staticcheck warning SA4006: never used value
2024-10-25 15:26:38 +08:00
Daniel Liu
739b4d7c60
Merge pull request #690 from gzliudan/fix-s1039
...
all: fix staticcheck warning S1039: unnecessary use of fmt.Sprintf
2024-10-25 15:25:56 +08:00
Daniel Liu
b9101e635d
Merge pull request #691 from gzliudan/fix-st1017
...
metrics: fix staticcheck warning ST1017: don't use yoda conditions
2024-10-25 15:25:29 +08:00
Daniel Liu
e9df8a11f0
Merge pull request #693 from gzliudan/rpc-peerinfo
...
fix staticcheck warning SA1029: inappropriate key in call to context.WithValue
2024-10-25 15:24:58 +08:00
Daniel Liu
48b1688e84
p2p/simulations: fix staticcheck warning SA1029
2024-10-25 12:32:32 +08:00
Daniel Liu
2844dbc5a9
rpc: fix staticcheck warning SA1029 by add PeerInfo ( #24255 )
2024-10-25 12:32:13 +08:00
Daniel Liu
c6e4e880ea
all: fix staticcheck warning SA4006: never used value
2024-10-24 17:37:19 +08:00
Daniel Liu
3409ada149
metrics: fix staticcheck warning ST1017: don't use yoda conditions
2024-10-24 16:07:11 +08:00
Daniel Liu
f79763ca88
all: fix staticcheck warning S1039: unnecessary use of fmt.Sprintf
2024-10-24 12:49:37 +08:00
Daniel Liu
a79411fa06
all: fix staticcheck warning ST1005: incorrectly formatted error string
2024-10-24 09:48:20 +08:00