From 05319d4f0f881be507eeeafe27ae63cfd4b6de7c Mon Sep 17 00:00:00 2001 From: Kyle Rames Date: Wed, 27 Nov 2013 11:26:59 -0600 Subject: [PATCH] [rackspace|queues] updating set_messages= to populate the claim_id attribute on messages in order for destroy to work properly. --- lib/fog/rackspace/models/queues/claim.rb | 4 +++- lib/fog/rackspace/models/queues/message.rb | 1 - 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/fog/rackspace/models/queues/claim.rb b/lib/fog/rackspace/models/queues/claim.rb index a397af647..c9ebb3787 100644 --- a/lib/fog/rackspace/models/queues/claim.rb +++ b/lib/fog/rackspace/models/queues/claim.rb @@ -80,12 +80,14 @@ module Fog }) attributes[:messages] = messages.collect do |message| if message.instance_of? Fog::Rackspace::Queues::Message + message.claim_id = self.id message else Fog::Rackspace::Queues::Message.new( message.merge({ :service => service, - :collection => message_collection + :collection => message_collection, + :claim_id => self.id }.merge(message)) ) end diff --git a/lib/fog/rackspace/models/queues/message.rb b/lib/fog/rackspace/models/queues/message.rb index 99fbf2a12..5769a7a3f 100644 --- a/lib/fog/rackspace/models/queues/message.rb +++ b/lib/fog/rackspace/models/queues/message.rb @@ -27,7 +27,6 @@ module Fog # @return [String] the id of the claim attribute :claim_id - # @!attribute [r] identity # @return [String] The messages identity def identity