almost looking for missing remote actors in cache

Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
alpha1
Maxence Lange 2018-11-29 13:31:08 -01:00
rodzic 7983a44b06
commit 1bc3373b8f
2 zmienionych plików z 22 dodań i 0 usunięć

Wyświetl plik

@ -105,6 +105,9 @@ class CacheRefresh extends Base {
$result = $this->actorService->manageCacheLocalActors();
$output->writeLn($result . ' local accounts regenerated');
$result = $this->personService->missingCacheRemoteActors();
$output->writeLn($result . ' remote accounts created');
$result = $this->personService->manageCacheRemoteActors();
$output->writeLn($result . ' remote accounts updated');

Wyświetl plik

@ -260,6 +260,25 @@ class PersonService implements ICoreService {
}
/**
* @throws Exception
* @return int
*/
public function missingCacheRemoteActors(): int {
// TODO - looking for missing cache remote actors...
$missing = [];
foreach ($missing as $item) {
try {
$this->getFromId($item->getId());
} catch (Exception $e) {
}
}
return sizeof($missing);
}
/**
* @throws Exception
* @return int