openassets-ruby 0.3.9 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/openassets/protocol/transaction_output.rb +11 -1
- data/lib/openassets/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 26c1b400f013171dd00cbf7c3418609b75c5fb01
|
4
|
+
data.tar.gz: 7cdfe632cd918eaeeedfa3ac92a7a115e10602b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b23f5a466673eb0ef65e37d4c9e38f7484e49bfd9637f04ed25f25096e5e7cd592bd1baeaaaadfdc7e0cb76a561f0d89d3eca0a2b2875f3b8805140a52d20801
|
7
|
+
data.tar.gz: 107f6811c94926ed8f8322dcde03cd73fae158ca007cf744822a9d40e1acdd15d16df52b97b78c36825ca74f765acf5bb19ec158dd63210f7ac71e1a8fb88184
|
@@ -57,7 +57,7 @@ module OpenAssets
|
|
57
57
|
def to_hash
|
58
58
|
{
|
59
59
|
'address' => address,
|
60
|
-
'oa_address' =>
|
60
|
+
'oa_address' => oa_address,
|
61
61
|
'script' => @script.to_payload.bth,
|
62
62
|
'amount' => satoshi_to_coin(@value),
|
63
63
|
'asset_id' => @asset_id,
|
@@ -74,6 +74,16 @@ module OpenAssets
|
|
74
74
|
script_to_address(@script)
|
75
75
|
end
|
76
76
|
|
77
|
+
def oa_address
|
78
|
+
a = address
|
79
|
+
return nil if a.nil?
|
80
|
+
if a.is_a?(Array)
|
81
|
+
a.map{|btc_address| address_to_oa_address(btc_address)}
|
82
|
+
else
|
83
|
+
address_to_oa_address(a)
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
77
87
|
private
|
78
88
|
|
79
89
|
@@definition_cache = {}
|
data/lib/openassets/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openassets-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- azuchi
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-04-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bitcoin-ruby
|