handle tags being null
in db, we store things as null (not set). but in rest api, we require the fields to be strings/arrays.
This commit is contained in:
+1
-1
@@ -299,7 +299,7 @@ function validateLabel(label) {
|
||||
}
|
||||
|
||||
function validateTags(tags) {
|
||||
assert(Array.isArray(tags), 'tags must be an array');
|
||||
if (tags === null) return null;
|
||||
|
||||
if (tags.length > 64) return new AppsError(AppsError.BAD_FIELD, 'Can only set up to 64 tags');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user