Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'feature/overload-dispatch-stage' into develop

  • Loading branch information...
commit 81f488bd474926c02915e66264aa2850416ad3f6 2 parents 6bfbc09 + 26ccd56
@trq trq authored
Showing with 13 additions and 4 deletions.
  1. +13 −4 lib/Proem/Bootstrap/Filter/Event/Dispatch.php
View
17 lib/Proem/Bootstrap/Filter/Event/Dispatch.php
@@ -110,7 +110,8 @@ function () use ($assets) {
*/
public function postIn(Manager $assets)
{
- $skipDispatch = false;
+ $skipDispatch = false;
+ $dispatchStageAsset = null;
if ($assets->provides('events', 'Proem\Signal\Manager\Template')) {
$assets->get('events')->trigger(
@@ -119,12 +120,20 @@ function ($response) use (&$skipDispatch) {
if ($response->has('skip.dispatch') && $response->getParam('skip.dispatch')) {
$skipDispatch = true;
}
+ if ($response->has('stage.asset')) {
+ $dispatchStageAsset = $response->get('stage.asset');
+ }
}
);
- }
- if (!$skipDispatch) {
- (new DispatchStage($assets));
+ if (!$skipDispatch) {
+ if ($dispatchStageAsset !== null) {
+ $dispatchStageAsset->setParam('assets', $assets);
+ $dispatchStageAsset->get();
+ } else {
+ (new DispatchStage($assets));
+ }
+ }
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.