|
@@ 79-83 (lines=5) @@
|
| 76 |
|
if ($config['existCheck'] === TRUE) { |
| 77 |
|
$ds = DIRECTORY_SEPARATOR; |
| 78 |
|
$filePath = $isVersion ? ($wwwDir . $ds . $path) : ($wwwDir . $ds . Utils::normalizePath($revision)); |
| 79 |
|
if ( ! file_exists($filePath)) { |
| 80 |
|
$msg = sprintf("Asset '%s' not found.", $filePath); |
| 81 |
|
Utils::throwError(new AssetNotFoundException($msg), $config['missingAsset'], $need); |
| 82 |
|
return ''; |
| 83 |
|
} |
| 84 |
|
} |
| 85 |
|
|
| 86 |
|
// Format output |
|
@@ 169-173 (lines=5) @@
|
| 166 |
|
|
| 167 |
|
// Path to JSON manifest |
| 168 |
|
if (is_string($manifest)) { |
| 169 |
|
if ( ! file_exists($manifest)) { |
| 170 |
|
$msg = sprintf("Manifest file not found: '%s'.", $manifest); |
| 171 |
|
Utils::throwError(new ManifestNotFoundException($msg), $config['missingManifest'], $need); |
| 172 |
|
return NULL; |
| 173 |
|
} |
| 174 |
|
return Json::decode(file_get_contents($manifest), Json::FORCE_ARRAY); |
| 175 |
|
} |
| 176 |
|
|