1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

More DRY, succinct implementation of tag parsing

This commit is contained in:
James Bence 2013-07-15 12:51:06 -07:00
parent 6fefaa7231
commit 018ae3815e

View file

@ -14,14 +14,12 @@ module Fog
end
def end_element(name)
case name
when 'LogFileData' then @response['DownloadDBLogFilePortionResult'][name] = value
when 'AdditionalDataPending' then @response['DownloadDBLogFilePortionResult'][name] = value
when 'Marker' then @response['DownloadDBLogFilePortionResult'][name] = value
when 'RequestId' then @response['ResponseMetadata'][name] = value
end
key = (name == 'RequestId') ? 'ResponseMetadata' : 'DownloadDBLogFilePortionResult'
@response[key][name] = value
end
end
end
end
end