diff --git a/sgx-bwmsgsv2.rb b/sgx-bwmsgsv2.rb index 7f4df8a655faed1505c70af40ac325f35cd2c94d..adb18dcb06d36d3f3ad5c2b6d40f9563eec60237 100755 --- a/sgx-bwmsgsv2.rb +++ b/sgx-bwmsgsv2.rb @@ -785,21 +785,11 @@ module SGXbwmsgsv2 }.catch(&method(:panic)) end - iq :get? do |i| - write_to_stream(error_msg( - i.reply, - i.children, - 'cancel', - 'feature-not-implemented' - )) - end - - iq :set? do |i| - write_to_stream(error_msg( - i.reply, - i.children, - 'cancel', - 'feature-not-implemented' + iq type: [:get, :set] do |iq| + write_to_stream(Blather::StanzaError.new( + iq, + 'feature-not-implemented', + :cancel )) end end