예제 #1
0
파일: Synker.php 프로젝트: ankhzet/Ankh
 protected function log($type, $value, Entity $entity = null)
 {
     if (is_array($value)) {
         $value = array_filter(array_filter($value, function ($property) {
             return !is_array($property);
         }));
         if ($value) {
             if (!($value = $entity->filterImportantUpdatedAttributes($value))) {
                 return;
             }
         }
         $value['id'] = $entity->id;
     } else {
         $value = array_merge(['id' => $entity->id], @$value);
     }
     $this->statistics[$type][] = $value;
 }