File tree 1 file changed +7
-2
lines changed
1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -43,11 +43,16 @@ def self.with_errors(errors)
43
43
if !errors . is_a? ( Hash ) || errors . empty?
44
44
new ( errors . to_s ) . with_errors ( EMPTY_HASH )
45
45
else
46
- messages = errors . map { |node_key , error | "#{ node_key } : (#{ error . class } ) #{ error . message } " }
46
+ messages = errors . map { |node_key , error | "#{ node_key } : (#{ error . class } ) #{ error . message } " } . freeze
47
47
new ( messages . join ( ', ' ) ) . with_errors ( errors )
48
48
end
49
49
end
50
50
51
+ def initialize ( error_message = nil )
52
+ @errors = nil
53
+ super
54
+ end
55
+
51
56
def with_errors ( errors )
52
57
@errors = errors if @errors . nil?
53
58
self
@@ -61,7 +66,7 @@ def self.from_command(command)
61
66
end
62
67
63
68
class NodeMightBeDown < Error
64
- def initialize ( _ = '' )
69
+ def initialize ( _error_message = nil )
65
70
super (
66
71
'The client is trying to fetch the latest cluster state ' \
67
72
'because a subset of nodes might be down. ' \
You can’t perform that action at this time.
0 commit comments