lib/opener/daemons/uploader.rb in opener-daemons-2.4.0 vs lib/opener/daemons/uploader.rb in opener-daemons-2.4.1
- old
+ new
@@ -28,10 +28,16 @@
##
# @param [Array] args
# @return [AWS::S3::S3Object]
#
def create(*args)
- return bucket.objects.create(*args)
+ object = bucket.objects.create(*args)
+
+ if object.is_a?(AWS::S3::ObjectVersion)
+ object = object.object
+ end
+
+ return object
end
##
# @return [AWS::S3.new]
#