mirror of
https://github.com/humhub/humhub.git
synced 2025-01-18 06:38:14 +01:00
51 lines
1.4 KiB
PHP
51 lines
1.4 KiB
PHP
<?php
|
|
|
|
/**
|
|
* HumHub
|
|
* Copyright © 2014 The HumHub Project
|
|
*
|
|
* The texts of the GNU Affero General Public License with an additional
|
|
* permission and of our proprietary license can be found at and
|
|
* in the LICENSE file you have received along with this program.
|
|
*
|
|
* According to our dual licensing model, this program can be used either
|
|
* under the terms of the GNU Affero General Public License, version 3,
|
|
* or under a proprietary license.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU Affero General Public License for more details.
|
|
*/
|
|
|
|
/**
|
|
* Site Controller
|
|
*
|
|
* @package humhub.controllers
|
|
* @since 0.5
|
|
*/
|
|
class SiteController extends Controller {
|
|
|
|
/**
|
|
* This is the default 'index' action that is invoked
|
|
* when an action is not explicitly requested by users.
|
|
*/
|
|
public function actionIndex() {
|
|
|
|
$this->redirect(array('dashboard/dashboard'));
|
|
}
|
|
|
|
/**
|
|
* This is the action to handle external exceptions.
|
|
*/
|
|
public function actionError() {
|
|
if ($error = Yii::app()->errorHandler->error) {
|
|
if (Yii::app()->request->isAjaxRequest)
|
|
echo $error['message'];
|
|
else
|
|
$this->render('error', $error);
|
|
}
|
|
}
|
|
|
|
}
|