Ejemplo n.º 1
0
 /**
  * Update location statistics
  * @param mongoId $accountId
  * @return boolean
  */
 private function updateLocationStatistics($accountId)
 {
     $memberStatistics = MemberStatistics::getByAccount($accountId);
     if (empty($memberStatistics)) {
         $memberStatistics = new MemberStatistics();
     }
     $locationStatistics = $this->getlocationStatistics($accountId);
     $memberStatistics->locationStatistics = $locationStatistics;
     $memberStatistics->accountId = $accountId;
     return $memberStatistics->save();
 }