mirror of
https://github.com/status-im/codimd.git
synced 2025-01-11 16:34:33 +00:00
Fix strip null byte in model should cast to string to use replace function
This commit is contained in:
parent
f55a4b8497
commit
4a1d08c653
@ -23,6 +23,7 @@ if (config.dburl) {
|
||||
// [Postgres] Handling NULL bytes
|
||||
// https://github.com/sequelize/sequelize/issues/6485
|
||||
function stripNullByte (value) {
|
||||
value = '' + value
|
||||
return value ? value.replace(/\u0000/g, '') : value
|
||||
}
|
||||
sequelize.stripNullByte = stripNullByte
|
||||
|
Loading…
x
Reference in New Issue
Block a user