]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Changed default declaration of $vars in elgg_view() to array().
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 21 Jan 2010 15:51:32 +0000 (15:51 +0000)
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 21 Jan 2010 15:51:32 +0000 (15:51 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@3823 36083f99-b078-4883-b0ff-0f9b5a30f544

engine/lib/elgglib.php

index 059e42fd74d2610face78efc4b994cbe3cb5bdc8..19451c1524e6690d2429ea7704210f9f5e13ea5f 100644 (file)
@@ -172,13 +172,13 @@ function elgg_get_view_location($view, $viewtype = '') {
  * @param string $viewtype If set, forces the viewtype for the elgg_view call to be this value (default: standard detection)
  * @return string The HTML content
  */
-function elgg_view($view, $vars = "", $bypass = false, $debug = false, $viewtype = '') {
+function elgg_view($view, $vars = array(), $bypass = false, $debug = false, $viewtype = '') {
        global $CONFIG;
        static $usercache;
 
        // basic checking for bad paths
        if (strpos($view, '..') !== false) {
-                       return false;
+               return false;
        }
 
        $view_orig = $view;
@@ -190,7 +190,7 @@ function elgg_view($view, $vars = "", $bypass = false, $debug = false, $viewtype
        }
 
        if (!is_array($usercache)) {
-                       $usercache = array();
+               $usercache = array();
        }
 
        if (!is_array($vars)) {
@@ -199,7 +199,7 @@ function elgg_view($view, $vars = "", $bypass = false, $debug = false, $viewtype
        }
 
        if (empty($vars)) {
-                       $vars = array();
+               $vars = array();
        }
 
        // Load session and configuration variables into $vars