mirror of https://github.com/reiseburo/hermann
Avoid adding non-existent children to our internal list.
This really only affects testing where we might be returning nil after a push_single expectation has been met
This commit is contained in:
parent
beb8c4764d
commit
b0d3bbffe3
|
@ -62,7 +62,9 @@ module Hermann
|
|||
|
||||
if RUBY_PLATFORM == "java"
|
||||
result = @internal.push_single(value, topic)
|
||||
@children << result
|
||||
unless result.nil?
|
||||
@children << result
|
||||
end
|
||||
# Reaping children on the push just to make sure that it does get
|
||||
# called correctly and we don't leak memory
|
||||
reap_children
|
||||
|
|
Loading…
Reference in New Issue