Samuel
Samuel
KKysely
Created by Samuel on 12/14/2023 in #help
TINYINT convert to bool
typeCast(field, next) {
if (field.type === 'TINY' && field.length === 1) {
return field.string() === '1'
} else {
return next();
}
}
typeCast(field, next) {
if (field.type === 'TINY' && field.length === 1) {
return field.string() === '1'
} else {
return next();
}
}
soultion was to use a typecast
4 replies