| Conditions | 1 |
| Paths | 4 |
| Total Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | 'use strict' |
||
| 6 | function getManifest (callback) { |
||
| 7 | jsonfile.readFile('module.json', function (err, module) { |
||
| 8 | if (err) { |
||
| 9 | output.err('Error reading module.json: ' + err) |
||
| 10 | return |
||
| 11 | } |
||
| 12 | if (!('slug' in module) || !module.slug || typeof module.slug !== 'string' || !module.slug.length) { |
||
| 13 | output.err('Please set a valid value for module.slug') |
||
| 14 | return |
||
| 15 | } |
||
| 16 | |||
| 17 | callback(module) |
||
| 18 | }) |
||
| 19 | } |
||
| 20 | |||
| 24 |