Bug fixed with scales with no offset

This commit is contained in:
Luis Fernando Molina committed 2020-01-20 14:58:49 +01:00
1 parent 0c8ff0fd80
commit 05debc3b55
1 file changed
+4
+4
View File
@@ -233,6 +233,10 @@ function newRateScale () {
saveObjectState()
return
}
if (isNaN(code.offset) || code.offset === null || code.offset === undefined) {
saveObjectState()
return
}
code.scale = code.scale / 100 * MAX_SCALE
if (code.scale < MIN_SCALE) { code.scale = MIN_SCALE }
if (code.scale > MAX_SCALE) { code.scale = MAX_SCALE }