lib/lightning/invoice.rb in lightning-invoice-0.1.4 vs lib/lightning/invoice.rb in lightning-invoice-0.1.5
- old
+ new
@@ -53,9 +53,14 @@
self.signature = sig.r.to_s(16).rjust(64, '0') + sig.s.to_s(16).rjust(64, '0')
self.signature += recovery
self
end
+ def ==(obj)
+ return false unless obj.is_a? Message
+ to_bech32 == obj.to_bech32
+ end
+
private
def to_human_string
human = +''
human << prefix