aboutsummaryrefslogtreecommitdiffstats
path: root/core/namespace/Application.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/namespace/Application.php')
-rw-r--r--core/namespace/Application.php14
1 files changed, 13 insertions, 1 deletions
diff --git a/core/namespace/Application.php b/core/namespace/Application.php
index 1597801..3cecf3b 100644
--- a/core/namespace/Application.php
+++ b/core/namespace/Application.php
@@ -44,7 +44,19 @@ class Application {
$username = self::get('DATABASE.USERNAME');
$password = self::get('DATABASE.PASSWORD');
- self::$Database = new Database($hostname, $basename, $username, $password);
+ $Database = new Database($hostname, $basename, $username, $password);
+
+ $Database->setAttribute(
+ $Database::ATTR_DEFAULT_FETCH_MODE,
+ $Database::FETCH_ASSOC
+ );
+
+ $Database->setAttribute(
+ $Database::ATTR_ERRMODE,
+ $Database::ERRMODE_EXCEPTION
+ );
+
+ self::$Database = $Database;
}
return self::$Database;