Lines Matching refs:errors
12 var errors = [] variable
15 errors.push('name cannot be null')
16 return done(warnings, errors)
20 errors.push('name cannot be undefined')
21 return done(warnings, errors)
25 errors.push('name must be a string')
26 return done(warnings, errors)
30 errors.push('name length must be greater than zero')
34 errors.push('name cannot start with a period')
38 errors.push('name cannot start with an underscore')
42 errors.push('name cannot contain leading or trailing spaces')
48 errors.push(blacklistedName + ' is a blacklisted name')
83 return done(warnings, errors)
87 errors.push('name can only contain URL-friendly characters')
90 return done(warnings, errors)
95 var done = function (warnings, errors) { argument
97 validForNewPackages: errors.length === 0 && warnings.length === 0,
98 validForOldPackages: errors.length === 0,
100 errors: errors property
103 if (!result.errors.length) delete result.errors