diff --git a/include/utils/VTCacheUtils.php b/include/utils/VTCacheUtils.php
index 579ee771d1e491789dc6ce2dc899dc5dfa0bfe12..1134965ef0e07ccf5efc074a79b2eec284b09d77 100644
--- a/include/utils/VTCacheUtils.php
+++ b/include/utils/VTCacheUtils.php
@@ -129,9 +129,9 @@ class VTCacheUtils {
 
         // If modulefields are already loaded then no need of this again
         if(!$modulefields){
-            $modulefields = array();
             $fieldInfo = Vtiger_Cache::get('ModuleFields',$tabid);
             if($fieldInfo){
+                $modulefields = array();
                 foreach($fieldInfo as $block => $blockFields){
                     foreach ($blockFields as $field){
                     if(in_array($field->get('presence'), $presencein)) {