Skip to content

Commit

Permalink
add missing method to api/admin
Browse files Browse the repository at this point in the history
  • Loading branch information
zelig authored and obscuren committed Jul 7, 2015
1 parent 2739233 commit 6391ec0
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
1 change: 1 addition & 0 deletions rpc/api/admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ var (
"admin_datadir": (*adminApi).DataDir,
"admin_startRPC": (*adminApi).StartRPC,
"admin_stopRPC": (*adminApi).StopRPC,
"admin_sleepBlocks": (*adminApi).SleepBlocks,
"admin_setGlobalRegistrar": (*adminApi).SetGlobalRegistrar,
"admin_setHashReg": (*adminApi).SetHashReg,
"admin_setUrlHint": (*adminApi).SetUrlHint,
Expand Down
18 changes: 16 additions & 2 deletions rpc/api/admin_js.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,13 @@ web3._extend({
inputFormatter: [web3._extend.utils.formatInputString],
outputFormatter: function(obj) { return obj; }
}),
new web3._extend.Method({
name: 'sleepBlocks',
call: 'admin_sleepBlocks',
params: 2,
inputFormatter: [web3._extend.utils.formatInputInt,web3._extend.utils.formatInputInt],
outputFormatter: web3._extend.formatters.formatOutputInt
}),
new web3._extend.Method({
name: 'verbosity',
call: 'admin_verbosity',
Expand Down Expand Up @@ -68,6 +75,13 @@ web3._extend({
inputFormatter: [web3._extend.utils.formatInputString,web3._extend.utils.formatInputString],
outputFormatter: web3._extend.formatters.formatOutputString
}),
new web3._extend.Method({
name: 'setUrlHint',
call: 'admin_setUrlHint',
params: 2,
inputFormatter: [web3._extend.utils.formatInputString,web3._extend.utils.formatInputString],
outputFormatter: web3._extend.formatters.formatOutputString
}),
new web3._extend.Method({
name: 'saveInfo',
call: 'admin_saveInfo',
Expand All @@ -90,14 +104,14 @@ web3._extend({
outputFormatter: web3._extend.formatters.formatOutputBool
}),
new web3._extend.Method({
name: 'StartNatSpec',
name: 'startNatSpec',
call: 'admin_startNatSpec',
params: 0,
inputFormatter: [],
outputFormatter: web3._extend.formatters.formatOutputBool
}),
new web3._extend.Method({
name: 'StopNatSpec',
name: 'stopNatSpec',
call: 'admin_stopNatSpec',
params: 0,
inputFormatter: [],
Expand Down

0 comments on commit 6391ec0

Please sign in to comment.