->db->count_all_results() will now return an integer instead of a string.
diff --git a/system/database/DB_active_rec.php b/system/database/DB_active_rec.php
index ee72dbb..db84713 100644
--- a/system/database/DB_active_rec.php
+++ b/system/database/DB_active_rec.php
@@ -1020,11 +1020,11 @@
if ($query->num_rows() == 0)
{
- return '0';
+ return 0;
}
$row = $query->row();
- return $row->numrows;
+ return (int) $row->numrows;
}
// --------------------------------------------------------------------
diff --git a/user_guide/changelog.html b/user_guide/changelog.html
index 008cbb7..bf86172 100644
--- a/user_guide/changelog.html
+++ b/user_guide/changelog.html
@@ -71,6 +71,11 @@
<li class="reactor">Added Environment Support for Hooks.</li>
</ul>
</li>
+ <li>Database
+ <ul>
+ <li class="reactor"><kbd>$this->db->count_all_results()</kbd> will now return an integer instead of a string.</li>
+ </ul>
+ </li>
</ul>
<h3>Bug fixes for 2.0.2</h3>