Merge pull request #4975 from cfaulkner/fix_ci_prepare_view_vars
Fix an Undefined variable: object error in CI_Loader
diff --git a/system/core/Loader.php b/system/core/Loader.php
index 17ff236..acfc739 100644
--- a/system/core/Loader.php
+++ b/system/core/Loader.php
@@ -1368,7 +1368,7 @@
* Prepare variables for _ci_vars, to be later extract()-ed inside views
*
* Converts objects to associative arrays and filters-out internal
- * variable names (i.e. keys prexied with '_ci_').
+ * variable names (i.e. keys prefixed with '_ci_').
*
* @param mixed $vars
* @return array
@@ -1378,7 +1378,7 @@
if ( ! is_array($vars))
{
$vars = is_object($vars)
- ? get_object_vars($object)
+ ? get_object_vars($vars)
: array();
}