peatio-electrum 2.6.0 → 2.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 50df12238fd4fba9831a9d92f2fec6ea8a30e53ebdc9271a443a042a01ec09ad
4
- data.tar.gz: 0b55deaab7a4ac88c31d1ab71f6e0d4b05feb562766d360a2b16c46aa208e878
3
+ metadata.gz: bd8974bd78b1fefd288202dae7efdac8ea326e061ad6a277f86c4544ffeb34fb
4
+ data.tar.gz: c231dfd84abd8fac23394b97c4a76a3eecb37dce9720a24bb615d0e7fed2007a
5
5
  SHA512:
6
- metadata.gz: e65206ef966d3d7fbae20bf284776ad4ac69a54376cbc8a85df52e9242c975c30af36fa8ebbcb9146132c29431ce74f85e13565c8c276ee20fec546c41bef472
7
- data.tar.gz: 3a869b3a570b0fb00000353d7332e87617a0d7e12c3bb0ef1d88da522f74fa70ae5146b09530f5500cb76169011d5b4ddaf97b99396491b404fe44afb8709ba7
6
+ metadata.gz: a23e16912618f80e879f8cdf9fa0abfa74caddfd80106940477a9784961b41ee989a2a7ea28170b4db6232a0b11460665ea122a8fc64b71f13f13d8b725c3c6a
7
+ data.tar.gz: 54883fe422a68eaa557783103f65e68f493dab81018f4e13760ef9e168c6009e275fb64e649f9eb9c34698e23feefd44bd308171b4af901c6e2d1d7163125d0b
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- peatio-electrum (2.6.0)
4
+ peatio-electrum (2.6.1)
5
5
  activesupport (~> 5.2.3)
6
6
  faraday (~> 0.17)
7
7
  net-http-persistent (~> 3.0.1)
@@ -10,9 +10,9 @@ PATH
10
10
  GEM
11
11
  remote: https://rubygems.org/
12
12
  specs:
13
- activemodel (5.2.4.2)
14
- activesupport (= 5.2.4.2)
15
- activesupport (5.2.4.2)
13
+ activemodel (5.2.4.3)
14
+ activesupport (= 5.2.4.3)
15
+ activesupport (5.2.4.3)
16
16
  concurrent-ruby (~> 1.0, >= 1.0.2)
17
17
  i18n (>= 0.7, < 2)
18
18
  minitest (~> 5.1)
@@ -35,7 +35,7 @@ GEM
35
35
  daemons (1.3.1)
36
36
  diff-lcs (1.3)
37
37
  docile (1.3.2)
38
- em-http-request (1.1.5)
38
+ em-http-request (1.1.6)
39
39
  addressable (>= 2.3.4)
40
40
  cookiejar (!= 0.3.1)
41
41
  em-socksify (>= 0.3)
@@ -72,7 +72,7 @@ GEM
72
72
  irb (1.2.4)
73
73
  reline (>= 0.0.1)
74
74
  jwt (2.2.1)
75
- minitest (5.14.0)
75
+ minitest (5.14.1)
76
76
  multi_json (1.14.1)
77
77
  multipart-post (2.1.1)
78
78
  mysql2 (0.5.3)
@@ -126,7 +126,7 @@ GEM
126
126
  addressable (>= 2.3.6)
127
127
  crack (>= 0.3.2)
128
128
  hashdiff (>= 0.4.0, < 2.0.0)
129
- websocket-driver (0.7.1)
129
+ websocket-driver (0.7.2)
130
130
  websocket-extensions (>= 0.1.0)
131
131
  websocket-extensions (0.1.4)
132
132
 
@@ -82,8 +82,20 @@ module Peatio::Electrum
82
82
  JSON.parse(call('history', [year, show_addresses, show_fiat, show_fees, from_height, to_height]))
83
83
  end
84
84
 
85
- def payto(destination, amount, fee = nil, from_addr = nil, change_addr = nil, nocheck = false, unsigned = false, rbf = nil, password = nil, locktime = nil)
86
- call('payto', [destination, amount, fee, from_addr, change_addr, nocheck, unsigned, rbf, password, locktime])
85
+ ## Default options:
86
+ ## fee: nil
87
+ ## from_addr: nil
88
+ ## change_addr: nil
89
+ ## nocheck: false
90
+ ## unsigned: false
91
+ ## rbf: nil
92
+ ## password: nil
93
+ ## locktime: nil
94
+ def payto(destination, amount, opts = {})
95
+ call('payto', {
96
+ destination: destination,
97
+ amount: amount
98
+ }.merge(opts).compact)
87
99
  end
88
100
 
89
101
  def broadcast(tx)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Peatio
4
4
  module Electrum
5
- VERSION = "2.6.0".freeze
5
+ VERSION = "2.6.1".freeze
6
6
  end
7
7
  end
@@ -89,7 +89,7 @@ module Peatio::Electrum
89
89
  # @raise [Peatio::Wallet::ClientError] if error was raised
90
90
  # on wallet API call.
91
91
  def create_transaction!(transaction, _options = {})
92
- tx = client.payto(transaction.to_address, transaction.amount)['hex']
92
+ tx = client.payto(transaction.to_address, transaction.amount, password: @settings[:wallet][:secret])['hex']
93
93
  txid = client.broadcast(tx)
94
94
  transaction.hash = txid
95
95
  transaction
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: peatio-electrum
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.6.0
4
+ version: 2.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Camille Meulien
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-05-15 00:00:00.000000000 Z
11
+ date: 2020-06-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport