coaster 0.3.7 → 0.3.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/coaster/core_ext/standard_error.rb +3 -3
- data/lib/coaster/version.rb +1 -1
- data/lib/coaster.rb +1 -1
- data/test/test_standard_error.rb +4 -4
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2e1e575098fbc51c407b9c468333b7a649229a8d
|
4
|
+
data.tar.gz: 00c04fe33a382b7809d6b7dfb130c96214100fc4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6c821cee7a557d1dab3f14ab413f13bddf98f69d634d5bce8c65cec0455d6e685b3f4f8ff5f07a744408d5fb514bda7e79dcdc9f3f58a53c49542a8a16ffdd7d
|
7
|
+
data.tar.gz: afe30ace49d932415b3f61942dd2cc37f39396aaa6606c53903acfbc94c341465e942b96e80206ea0d7e9f50ab2beabc9b91704f7dd6cb4c68699c2ec32cc465
|
@@ -15,14 +15,14 @@ class StandardError
|
|
15
15
|
|
16
16
|
def title
|
17
17
|
t = _translate('.title')
|
18
|
-
t.
|
18
|
+
t.instance_variable_defined?(:@missing) ? nil : t
|
19
19
|
end
|
20
20
|
end
|
21
21
|
|
22
22
|
attr_accessor :tags, :level, :tkey, :fingerprint
|
23
23
|
|
24
24
|
def initialize(message = nil, cause = $!)
|
25
|
-
@fingerprint = Coaster.default_fingerprint
|
25
|
+
@fingerprint = Coaster.default_fingerprint.dup
|
26
26
|
@tags = {}
|
27
27
|
@level = 'error'
|
28
28
|
@attributes = HashWithIndifferentAccess.new
|
@@ -61,7 +61,7 @@ class StandardError
|
|
61
61
|
|
62
62
|
@fingerprint = [] unless @fingerprint.is_a?(Array)
|
63
63
|
@tags = {} unless @tags.is_a?(Hash)
|
64
|
-
msg ||=
|
64
|
+
msg ||= self.class.title
|
65
65
|
super(msg)
|
66
66
|
end
|
67
67
|
|
data/lib/coaster/version.rb
CHANGED
data/lib/coaster.rb
CHANGED
data/test/test_standard_error.rb
CHANGED
@@ -44,13 +44,13 @@ module Coaster
|
|
44
44
|
"type"=>"Coaster::TestStandardError::ExampleError",
|
45
45
|
"status"=>20,
|
46
46
|
"http_status"=>500,
|
47
|
-
"message"=>"
|
47
|
+
"message"=>"Test this title",
|
48
48
|
"cause"=>{
|
49
49
|
"frog"=>"rams",
|
50
50
|
"type"=>"Coaster::TestStandardError::SampleError",
|
51
51
|
"status"=>10,
|
52
52
|
"http_status"=>500,
|
53
|
-
"message"=>"
|
53
|
+
"message"=>"Test this title"
|
54
54
|
}
|
55
55
|
}, e.to_hash)
|
56
56
|
end
|
@@ -74,7 +74,7 @@ module Coaster
|
|
74
74
|
rescue => e
|
75
75
|
detail = <<-LOG
|
76
76
|
[Coaster::TestStandardError::ExampleError] status:20
|
77
|
-
MESSAGE:
|
77
|
+
MESSAGE: Test this title
|
78
78
|
@fingerprint: []
|
79
79
|
@tags: {}
|
80
80
|
@level: \"error\"
|
@@ -82,7 +82,7 @@ module Coaster
|
|
82
82
|
@tkey: nil
|
83
83
|
@raven: {}
|
84
84
|
CAUSE: [Coaster::TestStandardError::SampleError] status:10
|
85
|
-
MESSAGE:
|
85
|
+
MESSAGE: Test this title
|
86
86
|
@fingerprint: []
|
87
87
|
@tags: {}
|
88
88
|
@level: \"error\"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: coaster
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- buzz jung
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: i18n
|