Skip to content
Snippets Groups Projects
Verified Commit 78e46677 authored by Alexander Olofsson's avatar Alexander Olofsson
Browse files

Unwrap wrapped errors

parent a4eba65d
No related branches found
No related tags found
No related merge requests found
Pipeline #167477 failed
......@@ -12,6 +12,10 @@ module Passwordstate
@code = code.to_i
@request = request
@response = response
if errors.count == 1 && errors.first.is_a?(Hash) && errors.first.key?('errors')
errors = errors.first['errors']
end
@errors = errors
errorstr = errors.map { |err| err['message'] || err['phrase'] || err['error'] }.join('; ')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment