We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c540d61 commit 868fae5Copy full SHA for 868fae5
src/Model.php
@@ -109,6 +109,15 @@ public static function set_db($db) {
109
110
return self::_error('db is not valid');
111
}
112
+
113
+ /**
114
+ * Get the DB object from the base Model
115
+ *
116
+ * @return DB
117
+ */
118
+ public static function get_db() {
119
+ return self::$db;
120
+ }
121
122
/**
123
* Register a model for the base class to use proper property data types and some other preps in the future
@@ -433,4 +442,4 @@ public function to_array($get_fields = null) {
433
442
434
443
435
444
436
-?>
445
+?>
0 commit comments