Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update EAuthWidget.php.

  • Loading branch information...
commit 5368baba4a35c3523fc26f068cbc5310df111b62 1 parent 5b00ae1
@Nodge authored
Showing with 16 additions and 3 deletions.
  1. +16 −3 EAuthWidget.php
View
19 EAuthWidget.php
@@ -33,11 +33,16 @@ class EAuthWidget extends CWidget {
* @var string the action to use for dialog destination. Default: the current route.
*/
public $action = null;
-
+
/**
- * Executes the widget.
+ * Initializes the widget.
+ * This method is called by {@link CBaseController::createWidget}
+ * and {@link CBaseController::beginWidget} after the widget's
+ * properties have been initialized.
*/
- public function run() {
+ public function init() {
+ parent::init();
+
// EAuth component
$component = Yii::app()->{$this->component};
@@ -50,6 +55,14 @@ public function run() {
// Set the current route, if it is not set.
if (!isset($this->action))
$this->action = Yii::app()->urlManager->parseUrl(Yii::app()->request);
+ }
+
+ /**
+ * Executes the widget.
+ * This method is called by {@link CBaseController::endWidget}.
+ */
+ public function run() {
+ parent::run();
$this->registerAssets();
$this->render('auth', array(
Please sign in to comment.
Something went wrong with that request. Please try again.