http.client: few more fixes.

db4
John Benediktsson 2014-03-12 19:49:58 -07:00
parent cb9c171383
commit ed5bc3b8fa
3 changed files with 3 additions and 3 deletions

View File

@ -183,7 +183,7 @@ PRIVATE>
: post-rpc ( rpc url -- rpc' ) : post-rpc ( rpc url -- rpc' )
! This needs to do something in the event of an error ! This needs to do something in the event of an error
rpc-post-request http-request* string>xml receive-rpc ; rpc-post-request http-request nip string>xml receive-rpc ;
: invoke-method ( params method url -- response ) : invoke-method ( params method url -- response )
[ swap <rpc-method> ] dip post-rpc ; [ swap <rpc-method> ] dip post-rpc ;

View File

@ -64,7 +64,7 @@ IN: bitcoin.client
payload bitcoin-url <post-request> payload bitcoin-url <post-request>
basic-auth "Authorization" set-header basic-auth "Authorization" set-header
dup post-data>> data>> length "Content-Length" set-header dup post-data>> data>> length "Content-Length" set-header
http-request* >string json> "result" of ; http-request nip >string json> "result" of ;
PRIVATE> PRIVATE>

View File

@ -60,7 +60,7 @@ MACRO: keys-boa ( keys class -- )
[ <oauth-request-params> set-oauth ] with-twitter-oauth ; [ <oauth-request-params> set-oauth ] with-twitter-oauth ;
: http-twitter-request ( request -- data ) : http-twitter-request ( request -- data )
set-request-twitter-auth http-request* ; inline set-request-twitter-auth http-request nip ; inline
PRIVATE> PRIVATE>