You are here

protected function ContentIndexerTrait::getContentIndex in Tome 8

Gets the contents of the index.

Return value

bool|array The index, or FALSE if there was an error.

1 call to ContentIndexerTrait::getContentIndex()
Importer::getChunkedNames in modules/tome_sync/src/Importer.php
Gets chunked arrays of content names to import.

File

modules/tome_sync/src/ContentIndexerTrait.php, line 151

Class

ContentIndexerTrait
Provides methods for reading and writing the index file.

Namespace

Drupal\tome_sync

Code

protected function getContentIndex() {
  $destination = $this
    ->getContentIndexFilePath();
  if (!file_exists($destination)) {
    return FALSE;
  }
  $contents = file_get_contents($destination);
  return json_decode($contents, TRUE);
}