lib/bitcoin/protocol/script_witness.rb in bitcoin-ruby-0.0.18 vs lib/bitcoin/protocol/script_witness.rb in bitcoin-ruby-0.0.19
- old
+ new
@@ -1,13 +1,11 @@
# encoding: ascii-8bit
module Bitcoin
-
module Protocol
-
+ # TxWitness section of https://en.bitcoin.it/wiki/Protocol_documentation#tx
class ScriptWitness
-
# witness stack
attr_reader :stack
def initialize
@stack = []
@@ -19,13 +17,10 @@
end
# output script in raw binary format
def to_payload
payload = Bitcoin::Protocol.pack_var_int(stack.size)
- payload << stack.map{|e| Bitcoin::Protocol.pack_var_int(e.bytesize) << e }.join
+ payload << stack.map { |e| Bitcoin::Protocol.pack_var_int(e.bytesize) << e }.join
end
-
end
-
end
-
-end
\ No newline at end of file
+end