mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-23 23:19:28 +00:00
Don't submit field that is empty when original value is null
This commit is contained in:
@@ -76,7 +76,8 @@ export default {
|
||||
if (new Date(this.original[k]).toString() != new Date(n[k]).toString())
|
||||
res[k] = n[k];
|
||||
} else {
|
||||
if (this.original[k] !== n[k])
|
||||
// TODO(chris): null && ""? should there be an exception for this?
|
||||
if (this.original[k] !== n[k] && !(this.original[k] === null && n[k] === ""))
|
||||
res[k] = n[k];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user