Skip to content

Commit

Permalink
fixed incognito redirects
Browse files Browse the repository at this point in the history
  • Loading branch information
Makreig authored Dec 11, 2017
1 parent 3fe902d commit 44cfbae
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions code/extensions/SystemMessageControllerExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ public function closesystemmessage()
$message->close();
}

if ($action->exists) {
return $this->owner->redirect($action->BackURL);
if ($action) {
return $this->owner->redirect(Director::get_current_page()->Link());
} else {
return $this->owner->redirectBack();
}
}
}
}

0 comments on commit 44cfbae

Please sign in to comment.