[editor] Fix: Removing cooldown resulted in save error

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2021-12-14 23:40:01 +01:00
parent 36f9133cd5
commit 21f9f80f3d
Signed by: luzifer
GPG key ID: 0066F03ED215AD7D

View file

@ -870,14 +870,20 @@ export default {
if (obj.cooldown) {
obj.cooldown = this.fixDurationRepresentationToInt64(obj.cooldown)
} else {
delete obj.cooldown
}
if (obj.channel_cooldown) {
obj.channel_cooldown = this.fixDurationRepresentationToInt64(obj.channel_cooldown)
} else {
delete obj.channel_cooldown
}
if (obj.user_cooldown) {
obj.user_cooldown = this.fixDurationRepresentationToInt64(obj.user_cooldown)
} else {
delete obj.user_cooldown
}
let promise = null