소스 검색

jsre, rpc/api: pull in new web3 and use hex numbers

Péter Szilágyi 10 년 전
부모
커밋
d4d3fc6a70
3개의 변경된 파일183개의 추가작업 그리고 134개의 파일을 삭제
  1. 180 127
      jsre/ethereum_js.go
  2. 3 3
      rpc/api/eth.go
  3. 0 4
      rpc/api/eth_js.go

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 180 - 127
jsre/ethereum_js.go


+ 3 - 3
rpc/api/eth.go

@@ -173,9 +173,9 @@ func (self *ethApi) IsSyncing(req *shared.Request) (interface{}, error) {
 
 	if current < height {
 		return map[string]interface{}{
-			"startingBlock": origin,
-			"currentBlock":  current,
-			"highestBlock":  height,
+			"startingBlock": newHexNum(big.NewInt(int64(origin)).Bytes()),
+			"currentBlock":  newHexNum(big.NewInt(int64(current)).Bytes()),
+			"highestBlock":  newHexNum(big.NewInt(int64(height)).Bytes()),
 		}, nil
 	}
 	return false, nil

+ 0 - 4
rpc/api/eth_js.go

@@ -42,10 +42,6 @@ web3._extend({
 		new web3._extend.Property({
 			name: 'pendingTransactions',
 			getter: 'eth_pendingTransactions'
-		}),
-		new web3._extend.Property({
-			name: 'syncing',
-			getter: 'eth_syncing'
 		})
 	]
 });

이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.