Skip to content

Commit

Permalink
Match more than one whitespace if present
Browse files Browse the repository at this point in the history
  • Loading branch information
mullermp committed Jun 5, 2024
1 parent 7a8b863 commit 88b20b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gems/aws-sdk-s3/lib/aws-sdk-s3/plugins/http_200_errors.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def members_in_body?(output)

def check_for_error(context)
xml = context.http_response.body_contents
if xml.match(/\?>\n<Error>/)
if xml.match(/\?>\s*<Error>/)
error_code = xml.match(/<Code>(.+?)<\/Code>/)[1]
error_message = xml.match(/<Message>(.+?)<\/Message>/)[1]
S3::Errors.error_class(error_code).new(context, error_message)
Expand Down

0 comments on commit 88b20b3

Please sign in to comment.