Merge pull request #7113 from Budibase/bug/sev3/options-picker-set-value-relationship-picker

Options picker set value for relationship picker - handle non-array values
This commit is contained in:
melohagan 2022-08-06 20:18:27 +01:00 committed by GitHub
commit 9bc7f400ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -55,6 +55,9 @@
if (!values) {
return []
}
if (!Array.isArray(values)) {
values = [values]
}
return values.map(value => (typeof value === "object" ? value._id : value))
}