Update form.js

This commit is contained in:
Torsten Dittmann
2021-04-06 15:40:24 +02:00
committed by GitHub
parent 7ee487a0cb
commit fd5ff9ac8f
+5 -1
View File
@@ -4,6 +4,10 @@
window.ls.container.set('form', function () {
function cast(value, to) {
if (value && Array.isArray(value) && to !== 'array') {
value = value.map(element => cast(element, to));
return value;
}
switch (to) {
case 'int':
case 'integer':
@@ -118,4 +122,4 @@
}
}, true, false);
})(window);
})(window);