fix(DataTable): undefined cell value fallback

This commit is contained in:
Nguyễn Trường Minh 2021-07-13 10:55:44 +07:00 committed by GitHub
commit 1e77748d77
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -132,7 +132,7 @@
.split(/[\.\[\]\'\"]/) .split(/[\.\[\]\'\"]/)
.filter((p) => p) .filter((p) => p)
.reduce( .reduce(
(o, p) => (o && typeof o === "object" && o[p] ? o[p] : defaultValue), (o, p) => ((o && typeof o === "object" && typeof o[p] === 'undefined') ? o[p] : defaultValue),
object object
); );