lib/pwn/plugins/jira_server.rb in pwn-0.4.654 vs lib/pwn/plugins/jira_server.rb in pwn-0.4.655
- old
+ new
@@ -69,17 +69,19 @@
else
raise @@logger.error("Unsupported HTTP Method #{http_method} for #{self} Plugin")
end
JSON.parse(response, symbolize_names: true)
- rescue StandardError => e
+ rescue ExceptionWithResponse => e
case e.message
when '400 Bad Request', '404 Resource Not Found'
"#{e.message}: #{e.response}"
else
raise e
end
+ rescue StandardError => e
+ raise e
ensure
spinner.stop
end
# Supported Method Parameters::
@@ -102,10 +104,10 @@
raise 'ERROR: issue cannot be nil.' if issue.nil?
rest_call(
base_api_uri: base_api_uri,
token: token,
- rest_call: "/issue/#{issue}"
+ rest_call: "issue/#{issue}"
)
rescue StandardError => e
raise e
end