54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
|
# File 'lib/sym/application.rb', line 54
def execute
execute!
rescue ::OpenSSL::Cipher::CipherError => e
{ reason: 'Invalid key provided',
exception: e }
rescue Sym::Errors::Error => e
{ reason: e.class.name.gsub(/.*::/, '').underscore.humanize.downcase,
exception: e }
rescue TypeError => e
if e.message =~ /marshal/m
{ reason: 'Corrupt source data or invalid/corrupt key provided',
exception: e }
else
{ exception: e }
end
rescue StandardError => e
{ exception: e }
end
|