Przeglądaj źródła

#104 - The very first notification issue.

AntonLV 11 lat temu
rodzic
commit
93e9ea1cc5
1 zmienionych plików z 5 dodań i 2 usunięć
  1. 5 2
      inc/classes/BxDolLiveUpdates.php

+ 5 - 2
inc/classes/BxDolLiveUpdates.php

@@ -159,9 +159,12 @@ class BxDolLiveUpdates extends BxDol
     				break;
     				break;
 
 
     			case 'data':
     			case 'data':
+    				if(!isset($aCached[$sType]))
+    					$aCached[$sType] = array();
+
     				$aRequested = $this->_getRequestedData();
     				$aRequested = $this->_getRequestedData();
-    				foreach($aRequested as $sName => $aData)
-    					$aCached[$sType][$sName] = $aData['count'];
+    				foreach($this->_aSystems as $sName => $aSystem)
+    					$aCached[$sType][$sName] = !empty($aRequested[$sName]['count']) ? (int)$aRequested[$sName]['count'] : 0;
     				break;
     				break;
     		}
     		}