Commit 10b45dd
committed
Fix Edge::Future#on_failure callbacks
When using future.on_failure {}; followed by future.fail("error"), I was getting:
NoMethodError: undefined method `apply' for #<Concurrent::Edge::Future::Failed:0x00000001aa87e0>
from /home/inecas/Projects/dynflow/concurrent-ruby/lib/concurrent/edge/future.rb:677:in `pr_callback_on_failure'
from /home/inecas/Projects/dynflow/concurrent-ruby/lib/concurrent/edge/future.rb:657:in `call_callback'
from /home/inecas/Projects/dynflow/concurrent-ruby/lib/concurrent/edge/future.rb:612:in `add_callback'
from /home/inecas/Projects/dynflow/concurrent-ruby/lib/concurrent/edge/future.rb:592:in `on_failure!'1 parent 2b4a6c7 commit 10b45dd
File tree
2 files changed
+26
-9
lines changed- lib/concurrent/edge
- spec/concurrent/edge
2 files changed
+26
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
456 | 456 | | |
457 | 457 | | |
458 | 458 | | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
459 | 463 | | |
460 | 464 | | |
461 | 465 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
172 | 185 | | |
173 | 186 | | |
174 | 187 | | |
| |||
0 commit comments