| Conditions | 3 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 17 | public static function create($descriptor = null, $basePath = null) |
||
| 18 | { |
||
| 19 | $descriptor = Utils::objectify($descriptor); |
||
| 20 | if ($descriptor && !isset($descriptor->resources)) { |
||
| 21 | $descriptor->resources = []; |
||
| 22 | } |
||
| 23 | $packageClass = Factory::getDatapackageClass($descriptor); |
||
| 24 | |||
| 25 | return new $packageClass($descriptor, $basePath, true); |
||
| 26 | } |
||
| 27 | } |
||
| 28 |