Skip to content

Commit

Permalink
[skip ci][auth] useAjax usage in AuthController constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
jcheron committed Feb 13, 2022
1 parent 06811b3 commit 0ba1d1d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/Ubiquity/controllers/auth/AuthController.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,15 @@ public function __construct($instance = null) {
$this->_controller = Startup::getController ();
$this->_action = Startup::getAction ();
$this->_actionParams = Startup::getActionParams ();
$this->_noAccessMsg = new FlashMessage ( 'You are not authorized to access the page <b>{url}</b> !', "Forbidden access", 'error', 'warning circle' );
$this->_noAccessMsg = new FlashMessage ( 'You are not authorized to access the page <b>{url}</b> !', 'Forbidden access', 'error', 'warning circle' );
$this->_loginCaption = 'Log in';
$this->_controllerInstance = $instance;
if (isset ( $instance ))
if (isset ( $instance )){
Startup::injectDependences ( $instance );
}
if($this->useAjax() && !URequest::isAjax()) {
$this->_addAjaxBehavior($instance->jquery??$this->jquery);
}
}

public function index() {
Expand Down

0 comments on commit 0ba1d1d

Please sign in to comment.