FluidTYPO3\Flux\FluxPackage::loadManifestFile PHP Method

loadManifestFile() protected method

Load flux.json manifest file by path or reference.
protected loadManifestFile ( string $filePathAndFilename ) : array
$filePathAndFilename string
return array
    protected function loadManifestFile($filePathAndFilename)
    {
        if (strpos($filePathAndFilename, '/') !== 0) {
            $absoluteManifestPath = GeneralUtility::getFileAbsFileName($filePathAndFilename);
        } else {
            $absoluteManifestPath = $filePathAndFilename;
        }
        if (!file_exists($absoluteManifestPath)) {
            throw new PackageNotFoundException(sprintf('Flux manifest file not found! I looked for %s - make sure the manifest exists.', $absoluteManifestPath));
        }
        return json_decode(file_get_contents($absoluteManifestPath), JSON_OBJECT_AS_ARRAY);
    }