Skip to content

Commit

Permalink
Merge pull request #4367 from vanilla/feature/after-analyze-request
Browse files Browse the repository at this point in the history
Fire a beforeAnalyzeRequest event so that plugins can modify the request after rewriting
  • Loading branch information
linc committed Aug 26, 2016
2 parents 19fe86f + 0c05443 commit df215a6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions library/core/class.dispatcher.php
Expand Up @@ -201,6 +201,9 @@ public function dispatch($ImportRequest = null, $Permanent = true) {
// We need to save this state now because it's lost after this method.
$this->passData('isHomepage', $this->isHomepage);

// Let plugins change augment the request before dispatch, but after internal routing.
$this->fireEvent('BeforeAnalyzeRequest');

// If we're in a private community and can block, redirect to signin
if (c('Garden.PrivateCommunity') && $this->getCanBlock($request) > self::BLOCK_PERMISSION) {
if ($this->deliveryType === DELIVERY_TYPE_DATA) {
Expand Down

0 comments on commit df215a6

Please sign in to comment.