Avoid normalizing empty fields (#645)
This commit is contained in:
parent
419adea234
commit
0a68b48acc
@ -45,6 +45,10 @@ function getEventData (req, res) {
|
||||
}
|
||||
|
||||
function normalizedField (field) {
|
||||
if (!field) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return field.toString().trim().substr(0, MAX_LENGTH);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user