1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-26 15:30:58 +01:00

Don't include requirements of non-providers in celerity map

Summary: Tests and docstubs don't provide anything and they are not required in celerity map.

Test Plan: View Options in Differential.

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, epriestley

Differential Revision: https://secure.phabricator.com/D1893
This commit is contained in:
vrana 2012-03-14 00:24:06 -07:00
parent af260c38cb
commit 0c728bd7a3

View file

@ -191,8 +191,12 @@ foreach ($file_map as $path => $info) {
$provides = array_filter($provides);
$requires = array_filter($requires);
if (!$provides) {
// Tests and documentation-only JS is permitted to @provide no targets.
continue;
}
if (count($provides) > 1) {
// NOTE: Documentation-only JS is permitted to @provide no targets.
throw new Exception(
"File {$path} must @provide at most one Celerity target.");
}