summaryrefslogtreecommitdiff
path: root/core/controllers
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2008-11-04 05:22:06 +0000
committerBharat Mediratta <bharat@menalto.com>2008-11-04 05:22:06 +0000
commitade1650846605d648da2565994e309414d908ac5 (patch)
treeb49d2e1fbda2a0bdd9de36954124fe82f6120d7f /core/controllers
parentf8b22c5aa9f70824004905fc864dead72bef67ea (diff)
Add a test to detect tabs in our code, and convert all tabs to spaces
so that the test passes.
Diffstat (limited to 'core/controllers')
-rw-r--r--core/controllers/welcome.php22
1 files changed, 11 insertions, 11 deletions
diff --git a/core/controllers/welcome.php b/core/controllers/welcome.php
index 93670cfe..f1201cff 100644
--- a/core/controllers/welcome.php
+++ b/core/controllers/welcome.php
@@ -74,18 +74,18 @@ class Welcome_Controller extends Template_Controller {
} else {
$old_handler = set_error_handler(array("Welcome_Controller", "_error_handler"));
try {
- Database::instance()->connect();
+ Database::instance()->connect();
} catch (Exception $e) {
- $error = new stdClass();
- $error->message = "Database error: {$e->getMessage()}";
- $db_name = Kohana::config("database.default.connection.database");
- if (strchr($error->message, "Unknown database")) {
- $error->instructions[] = "mysqladmin -uroot create $db_name";
- } else {
- $error->instructions = array();
- $error->message2 = "Check " . VARPATH . "database.php";
- }
- $errors[] = $error;
+ $error = new stdClass();
+ $error->message = "Database error: {$e->getMessage()}";
+ $db_name = Kohana::config("database.default.connection.database");
+ if (strchr($error->message, "Unknown database")) {
+ $error->instructions[] = "mysqladmin -uroot create $db_name";
+ } else {
+ $error->instructions = array();
+ $error->message2 = "Check " . VARPATH . "database.php";
+ }
+ $errors[] = $error;
}
set_error_handler($old_handler);
}