| Index: pkg/barback/lib/src/phase.dart
|
| diff --git a/pkg/barback/lib/src/phase.dart b/pkg/barback/lib/src/phase.dart
|
| index 48fd46f748dc60a865358f0df8487a9e529e0028..1230bea094e36970d402547ec6b386c868c33ec0 100644
|
| --- a/pkg/barback/lib/src/phase.dart
|
| +++ b/pkg/barback/lib/src/phase.dart
|
| @@ -148,6 +148,7 @@ class Phase {
|
| // Removing [output]'s listeners will cause it to be removed from
|
| // [_outputs], so we have to put it back.
|
| _outputs[output.output.id] = output;
|
| + output.output.whenRemoved.then((_) => _outputs.remove(output.output.id));
|
| _next.addInput(output.output);
|
| }
|
| return _next;
|
| @@ -188,8 +189,9 @@ class Phase {
|
| _outputs[asset.id].add(asset);
|
| } else {
|
| _outputs[asset.id] = new PhaseOutput(this, asset);
|
| - _outputs[asset.id].output.whenRemoved
|
| - .then((_) => _outputs.remove(asset.id));
|
| + _outputs[asset.id].output.whenRemoved.then((_) {
|
| + _outputs.remove(asset.id);
|
| + });
|
| if (_next != null) _next.addInput(_outputs[asset.id].output);
|
| }
|
| }
|
|
|