/**
  * @param mixed $event
  */
 public function afterInsert($event)
 {
     /* @var $row AlbumFileInformation */
     $row = $event->sender;
     /* @var $album Album */
     $album = $row->getAlbum()->one();
     $fileInformationList = AlbumFileInformation::find()->where(['album_id' => $album->getId()])->all();
     if (!is_array($fileInformationList)) {
         return;
     }
     $album->setPhotoCount(count($fileInformationList))->save();
 }